{
  "nbformat": 4,
  "nbformat_minor": 0,
  "metadata": {
    "colab": {
      "name": "AddFFNNEmbeddingstoCSV.ipynb",
      "version": "0.3.2",
      "provenance": []
    },
    "kernelspec": {
      "name": "python3",
      "display_name": "Python 3"
    },
    "accelerator": "GPU"
  },
  "cells": [
    {
      "metadata": {
        "id": "QKQlXhkY05Cf",
        "colab_type": "code",
        "outputId": "86e27c1f-7b61-41c0-f47b-f38a4e5dc80f",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 34
        }
      },
      "cell_type": "code",
      "source": [
        "from google.colab import drive\n",
        "drive.mount('/content/gdrive')"
      ],
      "execution_count": 0,
      "outputs": [
        {
          "output_type": "stream",
          "text": [
            "Drive already mounted at /content/gdrive; to attempt to forcibly remount, call drive.mount(\"/content/gdrive\", force_remount=True).\n"
          ],
          "name": "stdout"
        }
      ]
    },
    {
      "metadata": {
        "id": "GKYTdVN3zThA",
        "colab_type": "code",
        "outputId": "4300076e-a4a2-4b66-d59c-524701b681ce",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 353
        }
      },
      "cell_type": "code",
      "source": [
        "import numpy as np\n",
        "# install tf 2.0\n",
        "from __future__ import absolute_import, division, print_function, unicode_literals\n",
        "\n",
        "!pip install tensorflow-gpu==2.0.0-alpha0\n",
        "import tensorflow as tf\n",
        "# tf.compat.v1.disable_v2_behavior()\n",
        "\n",
        "print(tf.__version__)\n",
        "import requests\n",
        "import pandas as pd "
      ],
      "execution_count": 0,
      "outputs": [
        {
          "output_type": "stream",
          "text": [
            "Requirement already satisfied: tensorflow-gpu==2.0.0-alpha0 in /usr/local/lib/python3.6/dist-packages (2.0.0a0)\n",
            "Requirement already satisfied: numpy<2.0,>=1.14.5 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==2.0.0-alpha0) (1.16.3)\n",
            "Requirement already satisfied: astor>=0.6.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==2.0.0-alpha0) (0.7.1)\n",
            "Requirement already satisfied: gast>=0.2.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==2.0.0-alpha0) (0.2.2)\n",
            "Requirement already satisfied: tf-estimator-nightly<1.14.0.dev2019030116,>=1.14.0.dev2019030115 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==2.0.0-alpha0) (1.14.0.dev2019030115)\n",
            "Requirement already satisfied: protobuf>=3.6.1 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==2.0.0-alpha0) (3.7.1)\n",
            "Requirement already satisfied: keras-preprocessing>=1.0.5 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==2.0.0-alpha0) (1.0.9)\n",
            "Requirement already satisfied: termcolor>=1.1.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==2.0.0-alpha0) (1.1.0)\n",
            "Requirement already satisfied: grpcio>=1.8.6 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==2.0.0-alpha0) (1.15.0)\n",
            "Requirement already satisfied: keras-applications>=1.0.6 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==2.0.0-alpha0) (1.0.7)\n",
            "Requirement already satisfied: google-pasta>=0.1.2 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==2.0.0-alpha0) (0.1.5)\n",
            "Requirement already satisfied: wheel>=0.26 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==2.0.0-alpha0) (0.33.1)\n",
            "Requirement already satisfied: absl-py>=0.7.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==2.0.0-alpha0) (0.7.1)\n",
            "Requirement already satisfied: six>=1.10.0 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==2.0.0-alpha0) (1.12.0)\n",
            "Requirement already satisfied: tb-nightly<1.14.0a20190302,>=1.14.0a20190301 in /usr/local/lib/python3.6/dist-packages (from tensorflow-gpu==2.0.0-alpha0) (1.14.0a20190301)\n",
            "Requirement already satisfied: setuptools in /usr/local/lib/python3.6/dist-packages (from protobuf>=3.6.1->tensorflow-gpu==2.0.0-alpha0) (40.9.0)\n",
            "Requirement already satisfied: h5py in /usr/local/lib/python3.6/dist-packages (from keras-applications>=1.0.6->tensorflow-gpu==2.0.0-alpha0) (2.8.0)\n",
            "Requirement already satisfied: markdown>=2.6.8 in /usr/local/lib/python3.6/dist-packages (from tb-nightly<1.14.0a20190302,>=1.14.0a20190301->tensorflow-gpu==2.0.0-alpha0) (3.1)\n",
            "Requirement already satisfied: werkzeug>=0.11.15 in /usr/local/lib/python3.6/dist-packages (from tb-nightly<1.14.0a20190302,>=1.14.0a20190301->tensorflow-gpu==2.0.0-alpha0) (0.15.2)\n",
            "2.0.0-alpha0\n"
          ],
          "name": "stdout"
        }
      ]
    },
    {
      "metadata": {
        "id": "xrSVEUmZzX7O",
        "colab_type": "code",
        "colab": {}
      },
      "cell_type": "code",
      "source": [
        "def download_file_from_google_drive(id, destination):\n",
        "    URL = \"https://docs.google.com/uc?export=download\"\n",
        "\n",
        "    session = requests.Session()\n",
        "\n",
        "    response = session.get(URL, params = { 'id' : id }, stream = True)\n",
        "    token = get_confirm_token(response)\n",
        "\n",
        "    if token:\n",
        "        params = { 'id' : id, 'confirm' : token }\n",
        "        response = session.get(URL, params = params, stream = True)\n",
        "\n",
        "    save_response_content(response, destination)    \n",
        "\n",
        "def get_confirm_token(response):\n",
        "    for key, value in response.cookies.items():\n",
        "        if key.startswith('download_warning'):\n",
        "            return value\n",
        "\n",
        "    return None\n",
        "\n",
        "def save_response_content(response, destination):\n",
        "    CHUNK_SIZE = 32768\n",
        "\n",
        "    with open(destination, \"wb\") as f:\n",
        "        for chunk in response.iter_content(CHUNK_SIZE):\n",
        "            if chunk: # filter out keep-alive new chunks\n",
        "                f.write(chunk)"
      ],
      "execution_count": 0,
      "outputs": []
    },
    {
      "metadata": {
        "id": "TWsU2H7evFQc",
        "colab_type": "code",
        "outputId": "d88bb503-c727-4230-83b8-bd5fbe61e9f5",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 34
        }
      },
      "cell_type": "code",
      "source": [
        "pd.options.display.max_rows = 700\n",
        "pd.set_option('expand_frame_repr', True)\n",
        "pd.set_option('max_colwidth', 250)\n",
        "pd.set_option('expand_frame_repr', True)\n",
        "pd.get_option(\"display.max_rows\")"
      ],
      "execution_count": 0,
      "outputs": [
        {
          "output_type": "execute_result",
          "data": {
            "text/plain": [
              "700"
            ]
          },
          "metadata": {
            "tags": []
          },
          "execution_count": 7
        }
      ]
    },
    {
      "metadata": {
        "id": "WOiv_13Kzdj2",
        "colab_type": "code",
        "colab": {}
      },
      "cell_type": "code",
      "source": [
        "import os\n",
        "from glob import glob\n",
        "\n",
        "import numpy as np\n",
        "import pandas as pd\n",
        "import tensorflow as tf\n",
        "from sklearn.model_selection import train_test_split\n",
        "\n",
        "SEED = 42\n",
        "\n",
        "\n",
        "def _float_list_feature(value):\n",
        "    \"\"\"Returns a float_list from a float / double.\"\"\"\n",
        "    return tf.train.Feature(float_list=tf.train.FloatList(value=value))\n",
        "\n",
        "\n",
        "def _int64_list_feature(value):\n",
        "    \"\"\"Returns an int64_list from a bool / enum / int / uint.\"\"\"\n",
        "    return tf.train.Feature(int64_list=tf.train.Int64List(value=value))\n",
        "\n",
        "\n",
        "def _int64_feature(value):\n",
        "    \"\"\"Returns an int64_list from a bool / enum / int / uint.\"\"\"\n",
        "    return tf.train.Feature(int64_list=tf.train.Int64List(value=[value]))\n",
        "\n",
        "\n",
        "def create_generator_for_ffn(\n",
        "        file_list,\n",
        "        mode='train'):\n",
        "\n",
        "    # file_list = glob(os.path.join(data_dir, '*.csv'))\n",
        "\n",
        "    for full_file_path in file_list:\n",
        "        # full_file_path = os.path.join(data_dir, file_name)\n",
        "        if not os.path.exists(full_file_path):\n",
        "            raise FileNotFoundError(\"File %s not found\" % full_file_path)\n",
        "        df = pd.read_csv(full_file_path, encoding='utf8')\n",
        "\n",
        "        # so train test split\n",
        "        if mode == 'train':\n",
        "            df, _ = train_test_split(df, test_size=0.2, random_state=SEED)\n",
        "        else:\n",
        "            _, df = train_test_split(df, test_size=0.2, random_state=SEED)\n",
        "\n",
        "        for _, row in df.iterrows():\n",
        "            q_vectors = np.fromstring(row.question_bert.replace(\n",
        "                '[[', '').replace(']]', ''), sep=' ')\n",
        "            a_vectors = np.fromstring(row.answer_bert.replace(\n",
        "                '[[', '').replace(']]', ''), sep=' ')\n",
        "            vectors = np.stack([q_vectors, a_vectors], axis=0)\n",
        "            if mode in ['train', 'eval']:\n",
        "                print(vectors)                                      #added \n",
        "                yield vectors, 1\n",
        "            else:\n",
        "                print(vectors)                                        #added \n",
        "                yield vectors\n",
        "\n",
        "\n",
        "def ffn_serialize_fn(features):\n",
        "    features_tuple = {'features': _float_list_feature(\n",
        "        features[0].flatten()), 'labels': _int64_feature(features[1])}\n",
        "    example_proto = tf.train.Example(\n",
        "        features=tf.train.Features(feature=features_tuple))\n",
        "    return example_proto.SerializeToString()\n",
        "\n",
        "\n",
        "def make_tfrecord(data_dir, generator_fn, serialize_fn, suffix='', **kwargs):\n",
        "    \"\"\"Function to make TF Records from csv files\n",
        "    This function will take all csv files in data_dir, convert them\n",
        "    to tf example and write to *_{suffix}_train/eval.tfrecord to data_dir.\n",
        "\n",
        "    Arguments:\n",
        "        data_dir {str} -- dir that has csv files and store tf record\n",
        "        generator_fn {fn} -- A function that takes a list of filepath and yield the\n",
        "        parsed recored from file.\n",
        "        serialize_fn {fn} -- A function that takes output of generator fn and convert to tf example\n",
        "\n",
        "    Keyword Arguments:\n",
        "        suffix {str} -- suffix to add to tf record files (default: {''})\n",
        "    \"\"\"\n",
        "    file_list = glob(os.path.join(data_dir, '*.csv'))\n",
        "    train_tf_record_file_list = [\n",
        "        f.replace('.csv', '_{0}_train.tfrecord'.format(suffix)) for f in file_list]\n",
        "    test_tf_record_file_list = [\n",
        "        f.replace('.csv', '_{0}_eval.tfrecord'.format(suffix)) for f in file_list]\n",
        "    for full_file_path, train_tf_record_file_path, test_tf_record_file_path in zip(file_list, train_tf_record_file_list, test_tf_record_file_list):\n",
        "        print('Converting file {0} to TF Record'.format(full_file_path))\n",
        "        with tf.io.TFRecordWriter(train_tf_record_file_path) as writer:\n",
        "            for features in generator_fn([full_file_path], mode='train', **kwargs):\n",
        "                example = serialize_fn(features)\n",
        "                writer.write(example)\n",
        "        with tf.io.TFRecordWriter(test_tf_record_file_path) as writer:\n",
        "            for features in generator_fn([full_file_path], mode='eval', **kwargs):\n",
        "                example = serialize_fn(features)\n",
        "                writer.write(example)\n",
        "\n",
        "\n",
        "def create_dataset_for_ffn(\n",
        "        data_dir,\n",
        "        mode='train',\n",
        "        hidden_size=768,\n",
        "        shuffle_buffer=10000,\n",
        "        prefetch=10000,\n",
        "        batch_size=32):\n",
        "\n",
        "    tfrecord_file_list = glob(os.path.join(\n",
        "        data_dir, '*_FFN_{0}.tfrecord'.format((mode))))\n",
        "    if not tfrecord_file_list:\n",
        "        print('TF Record not found')\n",
        "        make_tfrecord(\n",
        "            data_dir, create_generator_for_ffn,\n",
        "            ffn_serialize_fn, 'FFN')\n",
        "\n",
        "    dataset = tf.data.TFRecordDataset(tfrecord_file_list)\n",
        "\n",
        "    def _parse_ffn_example(example_proto):\n",
        "        feature_description = {\n",
        "            'features': tf.io.FixedLenFeature([2*768], tf.float32),\n",
        "            'labels': tf.io.FixedLenFeature([], tf.int64, default_value=0),\n",
        "        }\n",
        "        feature_dict = tf.io.parse_single_example(\n",
        "            example_proto, feature_description)\n",
        "        return tf.reshape(feature_dict['features'], (2, 768)), feature_dict['labels']\n",
        "    dataset = dataset.map(_parse_ffn_example)\n",
        "\n",
        "    dataset = dataset.shuffle(shuffle_buffer)\n",
        "\n",
        "    dataset = dataset.prefetch(prefetch)\n",
        "\n",
        "    dataset = dataset.batch(batch_size)\n",
        "    return dataset"
      ],
      "execution_count": 0,
      "outputs": []
    },
    {
      "metadata": {
        "id": "PRwbUQeXzfKu",
        "colab_type": "code",
        "colab": {}
      },
      "cell_type": "code",
      "source": [
        "from __future__ import absolute_import, division, print_function, unicode_literals\n",
        "\n",
        "import os\n",
        "import pandas as pd\n",
        "from sklearn.model_selection import train_test_split\n",
        "import numpy as np\n",
        "\n",
        "import tensorflow as tf\n",
        "import tensorflow.keras.backend as K\n",
        "\n",
        "\n",
        "class FFN(tf.keras.layers.Layer):\n",
        "    def __init__(\n",
        "            self,\n",
        "            hidden_size=768,                                                                #SG edit from 768 4-24-19\n",
        "            dropout=0.2,\n",
        "            residual=True,\n",
        "            name='FFN',\n",
        "            **kwargs):\n",
        "        \"\"\"Simple Dense wrapped with various layers\n",
        "        \"\"\"\n",
        "\n",
        "        super(FFN, self).__init__(name=name, **kwargs)\n",
        "        self.hidden_size = hidden_size\n",
        "        self.dropout = dropout\n",
        "        self.residual = residual\n",
        "        self.ffn_layer = tf.keras.layers.Dense(\n",
        "            units=hidden_size,\n",
        "            use_bias=True\n",
        "        )\n",
        "\n",
        "    def call(self, inputs):\n",
        "        ffn_embedding = self.ffn_layer(inputs)\n",
        "        ffn_embedding = tf.keras.layers.ReLU()(ffn_embedding)\n",
        "        if self.dropout > 0:\n",
        "            ffn_embedding = tf.keras.layers.Dropout(\n",
        "                self.dropout)(ffn_embedding)\n",
        "#         ffn_embedding = self.ffn_layer(inputs)  #SG edit from 768 4-24-19\n",
        "#         ffn_embedding = tf.keras.layers.ReLU()(ffn_embedding)  #SG edit from 768 4-24-19\n",
        "#         if self.dropout > 0:  #SG edit from 768 4-24-19\n",
        "#             ffn_embedding = tf.keras.layers.Dropout(  #SG edit from 768 4-24-19\n",
        "#                 self.dropout)(ffn_embedding)  #SG edit from 768 4-24-19\n",
        "\n",
        "\n",
        "        if self.residual:\n",
        "            ffn_embedding += inputs\n",
        "        return ffn_embedding\n",
        "\n",
        "\n",
        "class MedicalQAModel(tf.keras.Model):\n",
        "    def __init__(self, name=''):\n",
        "        super(MedicalQAModel, self).__init__(name=name)\n",
        "        self.q_ffn = FFN(name='QFFN', input_shape=(768,))\n",
        "        self.a_ffn = FFN(name='AFFN', input_shape=(768,))\n",
        "\n",
        "    def call(self, inputs):\n",
        "#         print(inputs)\n",
        "#         tf.print(inputs)\n",
        "        q_bert_embedding, a_bert_embedding = tf.unstack(inputs, axis=1)\n",
        "#         print(q_bert_embedding)\n",
        "#         print(a_bert_embedding)\n",
        "#         tf.print(q_bert_embedding)\n",
        "#         tf.print(a_bert_embedding)\n",
        "        q_embedding, a_embedding = self.q_ffn(\n",
        "            q_bert_embedding), self.a_ffn(a_bert_embedding)\n",
        "        return tf.stack([q_embedding, a_embedding], axis=1)\n",
        "\n",
        "\n",
        "class BioBert(tf.keras.Model):\n",
        "    def __init__(self, name=''):\n",
        "        super(BioBert, self).__init__(name=name)\n",
        "\n",
        "    def call(self, inputs):\n",
        "\n",
        "        # inputs is dict with input features\n",
        "        input_ids, input_masks, segment_ids = inputs\n",
        "        # pass to bert\n",
        "        # with shape of (batch_size/2*batch_size, max_seq_len, hidden_size)\n",
        "        # TODO(Alex): Add true bert model\n",
        "        # Input: input_ids, input_masks, segment_ids all with shape (None, max_seq_len)\n",
        "        # Output: a tensor with shape (None, max_seq_len, hidden_size)\n",
        "        fake_bert_output = tf.expand_dims(tf.ones_like(\n",
        "            input_ids, dtype=tf.float32), axis=-1)*tf.ones([1, 1, 768], dtype=tf.float32)\n",
        "        max_seq_length = tf.shape(fake_bert_output)[-2]\n",
        "        hidden_size = tf.shape(fake_bert_output)[-1]\n",
        "\n",
        "        bert_output = tf.reshape(\n",
        "            fake_bert_output, (-1, 2, max_seq_length, hidden_size))\n",
        "        return bert_output\n",
        "\n",
        "\n",
        "class MedicalQAModelwithBert(tf.keras.Model):\n",
        "    def __init__(\n",
        "            self,\n",
        "            hidden_size=768,\n",
        "            dropout=0.2,\n",
        "            residual=True,\n",
        "            activation=tf.keras.layers.ReLU(),\n",
        "            name=''):\n",
        "        super(MedicalQAModelwithBert, self).__init__(name=name)\n",
        "        self.biobert = BioBert()\n",
        "        self.q_ffn_layer = FFN(\n",
        "            hidden_size=hidden_size,\n",
        "            dropout=dropout,\n",
        "            residual=residual,\n",
        "            activation=activation)\n",
        "        self.a_ffn_layer = FFN(\n",
        "            hidden_size=hidden_size,\n",
        "            dropout=dropout,\n",
        "            residual=residual,\n",
        "            activation=activation)\n",
        "\n",
        "    def _avg_across_token(self, tensor):\n",
        "        if tensor is not None:\n",
        "            tensor = tf.reduce_mean(tensor, axis=1)\n",
        "        return tensor\n",
        "\n",
        "    def call(self, inputs):\n",
        "\n",
        "        q_bert_embedding, a_bert_embedding = self.biobert(inputs)\n",
        "\n",
        "        # according to USE, the DAN network average embedding across tokens\n",
        "        q_bert_embedding = self._avg_across_token(q_bert_embedding)\n",
        "        a_bert_embedding = self._avg_across_token(a_bert_embedding)\n",
        "\n",
        "        q_embedding = self.q_ffn_layer(q_bert_embedding)\n",
        "        a_embedding = self.a_ffn_layer(a_bert_embedding)\n",
        "\n",
        "        return tf.stack([q_embedding, a_embedding], axis=1)\n",
        "\n",
        "      \n",
        "      \n",
        "# def qa_pair_cross_entropy_loss(y_true, y_pred):\n",
        "#     y_true = tf.eye(tf.shape(y_pred)[0])\n",
        "#     q_embedding, a_embedding = tf.unstack(y_pred, axis=1)\n",
        "#     similarity_matrix = tf.matmul(\n",
        "#         q_embedding, a_embedding, transpose_b=True)\n",
        "#     similarity_matrix_logits = tf.math.sigmoid(similarity_matrix)\n",
        "#     return tf.keras.losses.categorical_crossentropy(y_true, similarity_matrix_logits, from_logits=True)\n",
        "\n",
        "def qa_pair_cross_entropy_loss(y_true, y_pred):\n",
        "    y_true = tf.eye(tf.shape(y_pred)[0])\n",
        "    q_embedding, a_embedding = tf.unstack(y_pred, axis=1)\n",
        "    similarity_matrix = tf.matmul(\n",
        "        a = q_embedding, b = a_embedding, transpose_b=True)\n",
        "    similarity_matrix_softmaxed = tf.nn.softmax(similarity_matrix)\n",
        "    K.print_tensor(similarity_matrix_softmaxed, message=\"similarity_matrix_softmaxed is: \")\n",
        "    return tf.keras.losses.categorical_crossentropy(y_true, similarity_matrix_softmaxed, from_logits=False)\n",
        "\n"
      ],
      "execution_count": 0,
      "outputs": []
    },
    {
      "metadata": {
        "id": "_LVFHJL5znpm",
        "colab_type": "code",
        "colab": {}
      },
      "cell_type": "code",
      "source": [
        "# training config\n",
        "batch_size = 64\n",
        "num_epochs=35\n",
        "learning_rate=0.0001\n",
        "validation_split=0.2\n",
        "shuffle_buffer=50000\n",
        "prefetch=50000\n",
        "data_path='/content/gdrive/My Drive/mqa_tf_record'\n",
        "model_path = '/content/gdrive/My Drive/mqa_models/ffn_model_cross_entropy'"
      ],
      "execution_count": 0,
      "outputs": []
    },
    {
      "metadata": {
        "id": "GySah9vmzvVn",
        "colab_type": "code",
        "colab": {}
      },
      "cell_type": "code",
      "source": [
        "  d = create_dataset_for_ffn(\n",
        "      data_path, batch_size=batch_size, shuffle_buffer=shuffle_buffer, prefetch=prefetch)\n",
        "  eval_d = create_dataset_for_ffn(\n",
        "      data_path, batch_size=batch_size, mode='eval')\n",
        "  medical_qa_model = MedicalQAModel()\n",
        "  optimizer = tf.keras.optimizers.Adam(lr=learning_rate)\n",
        "  medical_qa_model.compile(\n",
        "      optimizer=optimizer, loss=qa_pair_cross_entropy_loss)\n",
        "\n",
        "  epochs = num_epochs\n",
        "  loss_metric = tf.keras.metrics.Mean()\n",
        "\n",
        "#   history = medical_qa_model.fit(d, epochs=epochs, validation_data=eval_d)\n",
        "#   history = medical_qa_model.train_on_batch(d)"
      ],
      "execution_count": 0,
      "outputs": []
    },
    {
      "metadata": {
        "id": "h1zDUw10zxwI",
        "colab_type": "code",
        "colab": {}
      },
      "cell_type": "code",
      "source": [
        "model_path2 = '/content/gdrive/My Drive/mqa_models/ffn_model_cross_entropy.ckpt'\n",
        "\n",
        "checkpoint = tf.keras.callbacks.ModelCheckpoint(model_path2, monitor='loss', verbose=1, save_best_only=True)"
      ],
      "execution_count": 0,
      "outputs": []
    },
    {
      "metadata": {
        "id": "1hkG6NfFzylm",
        "colab_type": "code",
        "outputId": "cfb5af6a-4e0e-4abe-95a0-a3393878fa7c",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 34
        }
      },
      "cell_type": "code",
      "source": [
        "checkpoint_dir = os.path.dirname(model_path2)\n",
        "print(checkpoint_dir)"
      ],
      "execution_count": 0,
      "outputs": [
        {
          "output_type": "stream",
          "text": [
            "/content/gdrive/My Drive/mqa_models\n"
          ],
          "name": "stdout"
        }
      ]
    },
    {
      "metadata": {
        "id": "vIvJIp7Pz0kN",
        "colab_type": "code",
        "outputId": "24b125a9-a1aa-4f83-feca-fb0c82ab9a31",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 34
        }
      },
      "cell_type": "code",
      "source": [
        "medical_qa_model.load_weights(model_path2)"
      ],
      "execution_count": 0,
      "outputs": [
        {
          "output_type": "execute_result",
          "data": {
            "text/plain": [
              "<tensorflow.python.training.tracking.util.CheckpointLoadStatus at 0x7f9cbad3f128>"
            ]
          },
          "metadata": {
            "tags": []
          },
          "execution_count": 16
        }
      ]
    },
    {
      "metadata": {
        "id": "q6OFGaC4z2cp",
        "colab_type": "code",
        "outputId": "202d0efa-7842-450f-9361-f564ef71185d",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 662
        }
      },
      "cell_type": "code",
      "source": [
        "history = medical_qa_model.fit(d, epochs=80, validation_data=eval_d )"
      ],
      "execution_count": 0,
      "outputs": [
        {
          "output_type": "stream",
          "text": [
            "Epoch 1/80\n"
          ],
          "name": "stdout"
        },
        {
          "output_type": "stream",
          "text": [
            "WARNING: Logging before flag parsing goes to stderr.\n",
            "W0427 05:23:58.006298 140313095235456 deprecation.py:323] From /usr/local/lib/python3.6/dist-packages/tensorflow/python/keras/backend.py:2924: Print (from tensorflow.python.ops.logging_ops) is deprecated and will be removed after 2018-08-20.\n",
            "Instructions for updating:\n",
            "Use tf.print instead of tf.Print. Note that tf.print returns a no-output operator that directly prints the output. Outside of defuns or eager mode, this operator will not be executed unless it is directly specified in session.run or used as a control dependency for other operators. This is only a concern in graph mode. Below is an example of how to ensure tf.print executes in graph mode:\n",
            "```python\n",
            "    sess = tf.Session()\n",
            "    with sess.as_default():\n",
            "        tensor = tf.range(10)\n",
            "        print_op = tf.print(tensor)\n",
            "        with tf.control_dependencies([print_op]):\n",
            "          out = tf.add(tensor, tensor)\n",
            "        sess.run(out)\n",
            "    ```\n",
            "Additionally, to use tf.print in python 2.7, users must make sure to import\n",
            "the following:\n",
            "\n",
            "  `from __future__ import print_function`\n",
            "\n"
          ],
          "name": "stderr"
        },
        {
          "output_type": "stream",
          "text": [
            "    253/Unknown - 14s 55ms/step - loss: 1.3278"
          ],
          "name": "stdout"
        },
        {
          "output_type": "error",
          "ename": "KeyboardInterrupt",
          "evalue": "ignored",
          "traceback": [
            "\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
            "\u001b[0;31mKeyboardInterrupt\u001b[0m                         Traceback (most recent call last)",
            "\u001b[0;32m<ipython-input-17-a31c84133dff>\u001b[0m in \u001b[0;36m<module>\u001b[0;34m()\u001b[0m\n\u001b[0;32m----> 1\u001b[0;31m \u001b[0mhistory\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mmedical_qa_model\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mfit\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0md\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mepochs\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0;36m80\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mvalidation_data\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0meval_d\u001b[0m \u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m",
            "\u001b[0;32m/usr/local/lib/python3.6/dist-packages/tensorflow/python/keras/engine/training.py\u001b[0m in \u001b[0;36mfit\u001b[0;34m(self, x, y, batch_size, epochs, verbose, callbacks, validation_split, validation_data, shuffle, class_weight, sample_weight, initial_epoch, steps_per_epoch, validation_steps, validation_freq, max_queue_size, workers, use_multiprocessing, **kwargs)\u001b[0m\n\u001b[1;32m    789\u001b[0m           \u001b[0mworkers\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0;36m0\u001b[0m\u001b[0;34m,\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m    790\u001b[0m           \u001b[0mshuffle\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0mshuffle\u001b[0m\u001b[0;34m,\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m--> 791\u001b[0;31m           initial_epoch=initial_epoch)\n\u001b[0m\u001b[1;32m    792\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m    793\u001b[0m     \u001b[0;31m# Case 3: Symbolic tensors or Numpy array-like.\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
            "\u001b[0;32m/usr/local/lib/python3.6/dist-packages/tensorflow/python/keras/engine/training.py\u001b[0m in \u001b[0;36mfit_generator\u001b[0;34m(self, generator, steps_per_epoch, epochs, verbose, callbacks, validation_data, validation_steps, validation_freq, class_weight, max_queue_size, workers, use_multiprocessing, shuffle, initial_epoch)\u001b[0m\n\u001b[1;32m   1513\u001b[0m         \u001b[0mshuffle\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0mshuffle\u001b[0m\u001b[0;34m,\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m   1514\u001b[0m         \u001b[0minitial_epoch\u001b[0m\u001b[0;34m=\u001b[0m\u001b[0minitial_epoch\u001b[0m\u001b[0;34m,\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m-> 1515\u001b[0;31m         steps_name='steps_per_epoch')\n\u001b[0m\u001b[1;32m   1516\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m   1517\u001b[0m   def evaluate_generator(self,\n",
            "\u001b[0;32m/usr/local/lib/python3.6/dist-packages/tensorflow/python/keras/engine/training_generator.py\u001b[0m in \u001b[0;36mmodel_iteration\u001b[0;34m(model, data, steps_per_epoch, epochs, verbose, callbacks, validation_data, validation_steps, validation_freq, class_weight, max_queue_size, workers, use_multiprocessing, shuffle, initial_epoch, mode, batch_size, steps_name, **kwargs)\u001b[0m\n\u001b[1;32m    255\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m    256\u001b[0m       \u001b[0mis_deferred\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0;32mnot\u001b[0m \u001b[0mmodel\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0m_is_compiled\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m--> 257\u001b[0;31m       \u001b[0mbatch_outs\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mbatch_function\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m*\u001b[0m\u001b[0mbatch_data\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m    258\u001b[0m       \u001b[0;32mif\u001b[0m \u001b[0;32mnot\u001b[0m \u001b[0misinstance\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mbatch_outs\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mlist\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m    259\u001b[0m         \u001b[0mbatch_outs\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0;34m[\u001b[0m\u001b[0mbatch_outs\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
            "\u001b[0;32m/usr/local/lib/python3.6/dist-packages/tensorflow/python/keras/engine/training.py\u001b[0m in \u001b[0;36mtrain_on_batch\u001b[0;34m(self, x, y, sample_weight, class_weight, reset_metrics)\u001b[0m\n\u001b[1;32m   1247\u001b[0m           output_loss_metrics=self._output_loss_metrics)\n\u001b[1;32m   1248\u001b[0m     \u001b[0;32melse\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m-> 1249\u001b[0;31m       \u001b[0;32mif\u001b[0m \u001b[0;32mnot\u001b[0m \u001b[0misinstance\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mK\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0msymbolic_learning_phase\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mint\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m   1250\u001b[0m         \u001b[0mins\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mx\u001b[0m \u001b[0;34m+\u001b[0m \u001b[0my\u001b[0m \u001b[0;34m+\u001b[0m \u001b[0msample_weights\u001b[0m \u001b[0;34m+\u001b[0m \u001b[0;34m[\u001b[0m\u001b[0;32mTrue\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m   1251\u001b[0m       \u001b[0;32melse\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
            "\u001b[0;32m/usr/local/lib/python3.6/dist-packages/tensorflow/python/keras/backend.py\u001b[0m in \u001b[0;36msymbolic_learning_phase\u001b[0;34m()\u001b[0m\n\u001b[1;32m    283\u001b[0m \u001b[0;32mdef\u001b[0m \u001b[0msymbolic_learning_phase\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m    284\u001b[0m   \u001b[0mgraph\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mget_graph\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m--> 285\u001b[0;31m   \u001b[0;32mwith\u001b[0m \u001b[0mgraph\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mas_default\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m    286\u001b[0m     \u001b[0;32mif\u001b[0m \u001b[0mgraph\u001b[0m \u001b[0;32mnot\u001b[0m \u001b[0;32min\u001b[0m \u001b[0m_GRAPH_LEARNING_PHASES\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m    287\u001b[0m       \u001b[0;32mwith\u001b[0m \u001b[0mops\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mname_scope\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m''\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
            "\u001b[0;32m/usr/lib/python3.6/contextlib.py\u001b[0m in \u001b[0;36m__enter__\u001b[0;34m(self)\u001b[0m\n\u001b[1;32m     79\u001b[0m     \u001b[0;32mdef\u001b[0m \u001b[0m__enter__\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mself\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m     80\u001b[0m         \u001b[0;32mtry\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m---> 81\u001b[0;31m             \u001b[0;32mreturn\u001b[0m \u001b[0mnext\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mgen\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m     82\u001b[0m         \u001b[0;32mexcept\u001b[0m \u001b[0mStopIteration\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m     83\u001b[0m             \u001b[0;32mraise\u001b[0m \u001b[0mRuntimeError\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m\"generator didn't yield\"\u001b[0m\u001b[0;34m)\u001b[0m \u001b[0;32mfrom\u001b[0m \u001b[0;32mNone\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
            "\u001b[0;32m/usr/local/lib/python3.6/dist-packages/tensorflow/python/framework/func_graph.py\u001b[0m in \u001b[0;36minner_cm\u001b[0;34m()\u001b[0m\n\u001b[1;32m    284\u001b[0m       \u001b[0mold_strategy_stack\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mself\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0m_distribution_strategy_stack\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m    285\u001b[0m       self._distribution_strategy_stack = list(\n\u001b[0;32m--> 286\u001b[0;31m           graph._distribution_strategy_stack)\n\u001b[0m\u001b[1;32m    287\u001b[0m       \u001b[0;31m# We ignore device placements from any outer scopes while tracing the\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m    288\u001b[0m       \u001b[0;31m# function when possible, to avoid hard-coding them in the function\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
            "\u001b[0;32m/usr/local/lib/python3.6/dist-packages/tensorflow/python/framework/ops.py\u001b[0m in \u001b[0;36m_distribution_strategy_stack\u001b[0;34m(self, _distribution_strategy_stack)\u001b[0m\n\u001b[1;32m   5053\u001b[0m   \u001b[0;32mdef\u001b[0m \u001b[0m_distribution_strategy_stack\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mself\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0m_distribution_strategy_stack\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m   5054\u001b[0m     self._thread_local._distribution_strategy_stack = (  # pylint: disable=protected-access\n\u001b[0;32m-> 5055\u001b[0;31m         _distribution_strategy_stack)\n\u001b[0m\u001b[1;32m   5056\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m   5057\u001b[0m   \u001b[0;34m@\u001b[0m\u001b[0mproperty\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
            "\u001b[0;31mKeyboardInterrupt\u001b[0m: "
          ]
        }
      ]
    },
    {
      "metadata": {
        "id": "cJJ6_py3vxQU",
        "colab_type": "code",
        "colab": {}
      },
      "cell_type": "code",
      "source": [
        "file_id = '1anbEwfViu9Rzu7tWKgPb_We1EwbA4x1-'\n",
        "\n",
        "download_file_from_google_drive(file_id, 'eHealthForum.csv')"
      ],
      "execution_count": 0,
      "outputs": []
    },
    {
      "metadata": {
        "id": "HYK2MDuywEC9",
        "colab_type": "code",
        "colab": {}
      },
      "cell_type": "code",
      "source": [
        "eHealthPD=pd.read_csv( 'eHealthForum.csv')"
      ],
      "execution_count": 0,
      "outputs": []
    },
    {
      "metadata": {
        "id": "tRUubW-MwNwU",
        "colab_type": "code",
        "outputId": "7797dfdb-901b-45a2-a7ad-d20ba57b43c7",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 699
        }
      },
      "cell_type": "code",
      "source": [
        "askDocspd.head()"
      ],
      "execution_count": 0,
      "outputs": [
        {
          "output_type": "execute_result",
          "data": {
            "text/html": [
              "<div>\n",
              "<style scoped>\n",
              "    .dataframe tbody tr th:only-of-type {\n",
              "        vertical-align: middle;\n",
              "    }\n",
              "\n",
              "    .dataframe tbody tr th {\n",
              "        vertical-align: top;\n",
              "    }\n",
              "\n",
              "    .dataframe thead th {\n",
              "        text-align: right;\n",
              "    }\n",
              "</style>\n",
              "<table border=\"1\" class=\"dataframe\">\n",
              "  <thead>\n",
              "    <tr style=\"text-align: right;\">\n",
              "      <th></th>\n",
              "      <th>question</th>\n",
              "      <th>answer</th>\n",
              "      <th>question_bert</th>\n",
              "      <th>answer_bert</th>\n",
              "    </tr>\n",
              "  </thead>\n",
              "  <tbody>\n",
              "    <tr>\n",
              "      <th>0</th>\n",
              "      <td>Trying to get y friend to see a doctor but she wants to wait and see what happens. I'm worried sick and would like to know hat she might haveMy friend found a dime sized red lump a bit to the right of her clitoris in the shower this morning. its ...</td>\n",
              "      <td>This is most likely a Bartholin's Gland Cyst. On either side of the labia majora is a called a Bartholin's gland. Occasionally the ducts that empty the gland can become blocked causing the gland to develop a cyst. Sometimes they can go away on th...</td>\n",
              "      <td>[[ 5.03139086e-02  1.75226659e-01 -1.97714433e-01 -7.32559934e-02\\n   3.20691824e-01 -1.78071290e-01  2.48940829e-02 -3.78650844e-01\\n  -3.47410381e-01  2.75857508e-01 -2.56084532e-01  2.22180486e-01\\n  -1.10391743e-01  1.29870668e-01  1.20820425...</td>\n",
              "      <td>[[-9.86990631e-02  2.09356025e-01 -4.21857655e-01 -3.36655468e-01\\n   4.87976819e-01 -7.02803209e-03 -3.16477306e-02 -1.65782422e-01\\n  -2.62371778e-01  2.40044087e-01 -2.24384233e-01  1.41379043e-01\\n   1.54396653e-01 -2.18005907e-02  1.46356851...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>1</th>\n",
              "      <td>Ease my worries pleaseMy husband is about to see a hematologist and googling around has me worried that he's got something serious, like aplastic anemia. I know we'll find out soon enough, but in the meantime, could you please suggest alternative...</td>\n",
              "      <td>Would be helpful with the exact values of the CBC. And B12, Folate and Ferritin values.\\n\\nAre liver and kidney function tests okay?\\n\\nWhat are his ethnic origins?,Is he diabetic. Does he take any other medication?,Does he take aspirin?\\nDid he ...</td>\n",
              "      <td>[[-6.82685152e-02  4.29603830e-02 -3.32764566e-01 -6.10484481e-02\\n   1.12031415e-01 -2.02944130e-01 -9.14147869e-02 -2.58494318e-01\\n  -2.18344301e-01  2.87112653e-01 -6.67973831e-02 -9.51428413e-02\\n  -8.95148739e-02 -1.64768383e-01  2.71721900...</td>\n",
              "      <td>[[ 2.15814300e-02 -8.26028138e-02 -1.79856256e-01 -1.90481871e-01\\n   2.28367019e-02 -9.73006934e-02 -1.17688790e-01 -1.57697827e-01\\n  -1.08430490e-01  1.52954862e-01  1.85464919e-01 -1.62801355e-01\\n   2.00268812e-02 -2.12160777e-02  4.19895537...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>2</th>\n",
              "      <td>Severe shoulder, neck and back pain after tetanus vaccinationA little less than a week ago I received my tetanus booster shot (the one you receive every decade, at least here in Australia).\\n\\nA few days later I began experiencing pain around my ...</td>\n",
              "      <td>I seriously don't think your pain derives from the vaccination.\\n\\nIt looks like trapezoid contracture (is it the right word in english?).\\n\\nHeat and posture care should help you, elseways some muscular relaxant could be helpful.\\n\\nAnyways, at ...</td>\n",
              "      <td>[[-9.59900767e-02  3.72468904e-02 -3.78887504e-01 -4.50596698e-02\\n   1.33349165e-01 -4.34329249e-02  4.04662602e-02 -2.44166061e-01\\n  -1.02068119e-01  4.49610293e-01 -5.45308404e-02 -8.46140832e-02\\n  -4.96546812e-02 -2.82016784e-01  3.25671524...</td>\n",
              "      <td>[[-1.67309746e-01  6.44435063e-02  9.25731473e-03  1.30308941e-01\\n   1.98665693e-01  1.11179024e-01  3.86667326e-02 -2.81090587e-01\\n  -1.66967526e-01  2.28748009e-01  6.09516762e-02  2.41061822e-02\\n   2.80033629e-02 -1.44916847e-01  2.37973034...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>3</th>\n",
              "      <td>Knee problemHere's the run down.  This past weekend my wife and I took part in a 3-day walk for breast cancer.  It was 60 miles, so clearly a lot of work on my knees.  Day 1 went fine, feet hurt, but to be expected.  Day two came and I was having...</td>\n",
              "      <td>It's possible that you caused some damage while playing sports and now with a heavy amount of activity caused aggravation of that injury. Its possible to cause a small tear in a meniscus and go years without any problems until a specific event ca...</td>\n",
              "      <td>[[-1.29183223e-02 -2.05045454e-02 -5.12924075e-01 -1.66846707e-01\\n   7.68833160e-02 -2.10388333e-01 -1.76014677e-01 -1.63012460e-01\\n  -2.01517850e-01  4.29517597e-01 -5.23534641e-02  1.08745629e-02\\n  -2.42132619e-02  2.21630232e-03  2.81971633...</td>\n",
              "      <td>[[-6.90914094e-02 -1.75325274e-01 -2.17794701e-01 -3.16970319e-01\\n   4.53783050e-02  2.69050837e-01 -8.84563774e-02 -5.35140410e-02\\n  -1.40716955e-01  2.62832701e-01  5.61185367e-02 -7.53825307e-02\\n  -3.30312178e-03 -1.45833969e-01  7.09648505...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>4</th>\n",
              "      <td>Had a strange experience last night.Woke up in the middle of the night to take a leak. As I flushed the toilet I remember standing there feeling very light headed. I turned around and started to walk back to bed but never made it. Apparently I pa...</td>\n",
              "      <td>Sounds like you had an episode of positional hypotension leading to syncope, or in other words, you stood up too fast causing a drop in blood pressure which made you pass out. If this was a one time thing you don't need to worry about it. Its pos...</td>\n",
              "      <td>[[-1.07785672e-01  7.25684240e-02 -3.21571469e-01 -3.26673627e-01\\n   1.79342732e-01 -4.22933251e-02 -4.46543284e-02 -3.20031524e-01\\n  -3.15706164e-01  4.07414287e-01 -2.55068183e-01 -8.69708136e-02\\n  -1.83549866e-01  6.94538057e-02  2.84941673...</td>\n",
              "      <td>[[ 1.17936537e-01  3.22081089e-01 -2.68315077e-01 -3.22643697e-01\\n   2.45345443e-01  1.22372217e-01 -6.57593310e-02 -3.15712541e-01\\n  -4.09232318e-01  3.51304054e-01 -1.17886476e-01 -1.15702309e-01\\n  -1.23623818e-01  5.74846864e-02 -5.51498830...</td>\n",
              "    </tr>\n",
              "  </tbody>\n",
              "</table>\n",
              "</div>"
            ],
            "text/plain": [
              "                                                                                                                                                                                                                                                    question  \\\n",
              "0  Trying to get y friend to see a doctor but she wants to wait and see what happens. I'm worried sick and would like to know hat she might haveMy friend found a dime sized red lump a bit to the right of her clitoris in the shower this morning. its ...   \n",
              "1  Ease my worries pleaseMy husband is about to see a hematologist and googling around has me worried that he's got something serious, like aplastic anemia. I know we'll find out soon enough, but in the meantime, could you please suggest alternative...   \n",
              "2  Severe shoulder, neck and back pain after tetanus vaccinationA little less than a week ago I received my tetanus booster shot (the one you receive every decade, at least here in Australia).\\n\\nA few days later I began experiencing pain around my ...   \n",
              "3  Knee problemHere's the run down.  This past weekend my wife and I took part in a 3-day walk for breast cancer.  It was 60 miles, so clearly a lot of work on my knees.  Day 1 went fine, feet hurt, but to be expected.  Day two came and I was having...   \n",
              "4  Had a strange experience last night.Woke up in the middle of the night to take a leak. As I flushed the toilet I remember standing there feeling very light headed. I turned around and started to walk back to bed but never made it. Apparently I pa...   \n",
              "\n",
              "                                                                                                                                                                                                                                                      answer  \\\n",
              "0  This is most likely a Bartholin's Gland Cyst. On either side of the labia majora is a called a Bartholin's gland. Occasionally the ducts that empty the gland can become blocked causing the gland to develop a cyst. Sometimes they can go away on th...   \n",
              "1  Would be helpful with the exact values of the CBC. And B12, Folate and Ferritin values.\\n\\nAre liver and kidney function tests okay?\\n\\nWhat are his ethnic origins?,Is he diabetic. Does he take any other medication?,Does he take aspirin?\\nDid he ...   \n",
              "2  I seriously don't think your pain derives from the vaccination.\\n\\nIt looks like trapezoid contracture (is it the right word in english?).\\n\\nHeat and posture care should help you, elseways some muscular relaxant could be helpful.\\n\\nAnyways, at ...   \n",
              "3  It's possible that you caused some damage while playing sports and now with a heavy amount of activity caused aggravation of that injury. Its possible to cause a small tear in a meniscus and go years without any problems until a specific event ca...   \n",
              "4  Sounds like you had an episode of positional hypotension leading to syncope, or in other words, you stood up too fast causing a drop in blood pressure which made you pass out. If this was a one time thing you don't need to worry about it. Its pos...   \n",
              "\n",
              "                                                                                                                                                                                                                                               question_bert  \\\n",
              "0  [[ 5.03139086e-02  1.75226659e-01 -1.97714433e-01 -7.32559934e-02\\n   3.20691824e-01 -1.78071290e-01  2.48940829e-02 -3.78650844e-01\\n  -3.47410381e-01  2.75857508e-01 -2.56084532e-01  2.22180486e-01\\n  -1.10391743e-01  1.29870668e-01  1.20820425...   \n",
              "1  [[-6.82685152e-02  4.29603830e-02 -3.32764566e-01 -6.10484481e-02\\n   1.12031415e-01 -2.02944130e-01 -9.14147869e-02 -2.58494318e-01\\n  -2.18344301e-01  2.87112653e-01 -6.67973831e-02 -9.51428413e-02\\n  -8.95148739e-02 -1.64768383e-01  2.71721900...   \n",
              "2  [[-9.59900767e-02  3.72468904e-02 -3.78887504e-01 -4.50596698e-02\\n   1.33349165e-01 -4.34329249e-02  4.04662602e-02 -2.44166061e-01\\n  -1.02068119e-01  4.49610293e-01 -5.45308404e-02 -8.46140832e-02\\n  -4.96546812e-02 -2.82016784e-01  3.25671524...   \n",
              "3  [[-1.29183223e-02 -2.05045454e-02 -5.12924075e-01 -1.66846707e-01\\n   7.68833160e-02 -2.10388333e-01 -1.76014677e-01 -1.63012460e-01\\n  -2.01517850e-01  4.29517597e-01 -5.23534641e-02  1.08745629e-02\\n  -2.42132619e-02  2.21630232e-03  2.81971633...   \n",
              "4  [[-1.07785672e-01  7.25684240e-02 -3.21571469e-01 -3.26673627e-01\\n   1.79342732e-01 -4.22933251e-02 -4.46543284e-02 -3.20031524e-01\\n  -3.15706164e-01  4.07414287e-01 -2.55068183e-01 -8.69708136e-02\\n  -1.83549866e-01  6.94538057e-02  2.84941673...   \n",
              "\n",
              "                                                                                                                                                                                                                                                 answer_bert  \n",
              "0  [[-9.86990631e-02  2.09356025e-01 -4.21857655e-01 -3.36655468e-01\\n   4.87976819e-01 -7.02803209e-03 -3.16477306e-02 -1.65782422e-01\\n  -2.62371778e-01  2.40044087e-01 -2.24384233e-01  1.41379043e-01\\n   1.54396653e-01 -2.18005907e-02  1.46356851...  \n",
              "1  [[ 2.15814300e-02 -8.26028138e-02 -1.79856256e-01 -1.90481871e-01\\n   2.28367019e-02 -9.73006934e-02 -1.17688790e-01 -1.57697827e-01\\n  -1.08430490e-01  1.52954862e-01  1.85464919e-01 -1.62801355e-01\\n   2.00268812e-02 -2.12160777e-02  4.19895537...  \n",
              "2  [[-1.67309746e-01  6.44435063e-02  9.25731473e-03  1.30308941e-01\\n   1.98665693e-01  1.11179024e-01  3.86667326e-02 -2.81090587e-01\\n  -1.66967526e-01  2.28748009e-01  6.09516762e-02  2.41061822e-02\\n   2.80033629e-02 -1.44916847e-01  2.37973034...  \n",
              "3  [[-6.90914094e-02 -1.75325274e-01 -2.17794701e-01 -3.16970319e-01\\n   4.53783050e-02  2.69050837e-01 -8.84563774e-02 -5.35140410e-02\\n  -1.40716955e-01  2.62832701e-01  5.61185367e-02 -7.53825307e-02\\n  -3.30312178e-03 -1.45833969e-01  7.09648505...  \n",
              "4  [[ 1.17936537e-01  3.22081089e-01 -2.68315077e-01 -3.22643697e-01\\n   2.45345443e-01  1.22372217e-01 -6.57593310e-02 -3.15712541e-01\\n  -4.09232318e-01  3.51304054e-01 -1.17886476e-01 -1.15702309e-01\\n  -1.23623818e-01  5.74846864e-02 -5.51498830...  "
            ]
          },
          "metadata": {
            "tags": []
          },
          "execution_count": 18
        }
      ]
    },
    {
      "metadata": {
        "id": "vl36QQODqU9y",
        "colab_type": "code",
        "colab": {}
      },
      "cell_type": "code",
      "source": [
        "def QgetEmbeds(x):\n",
        "    qt = x['question_bert']\n",
        "    at = x['answer_bert']\n",
        "    qtn = np.fromstring(\n",
        "                               qt.replace('\\n','')\n",
        "                                .replace('[','')\n",
        "                                .replace(']','')\n",
        "                                .replace('  ',' '), sep=' ')\n",
        "    atn = np.fromstring(\n",
        "                               at.replace('\\n','')\n",
        "                                .replace('[','')\n",
        "                                .replace(']','')\n",
        "                                .replace('  ',' '), sep=' ')\n",
        "    textinput = tf.constant([qtn, atn])\n",
        "    textinputF = tf.dtypes.cast(textinput , dtype=tf.float32) \n",
        "    textinputE = tf.expand_dims(textinputF, 0)\n",
        "#     trythis = medical_qa_model(textinputE)\n",
        "    q_embedding, a_embedding = tf.unstack(medical_qa_model(textinputE), axis=1)\n",
        "    return q_embedding.numpy()"
      ],
      "execution_count": 0,
      "outputs": []
    },
    {
      "metadata": {
        "id": "oyN0B2SSqmao",
        "colab_type": "code",
        "colab": {}
      },
      "cell_type": "code",
      "source": [
        "askDocspd['Q_FFNN_embeds'] = askDocspd.apply(QgetEmbeds, axis=1)"
      ],
      "execution_count": 0,
      "outputs": []
    },
    {
      "metadata": {
        "id": "fle9z5WYtL2G",
        "colab_type": "code",
        "outputId": "134687e6-2eb2-45bf-b65a-438ade86a3c7",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 138
        }
      },
      "cell_type": "code",
      "source": [
        "askDocspd['Q_FFNN_embeds'].head()"
      ],
      "execution_count": 0,
      "outputs": [
        {
          "output_type": "execute_result",
          "data": {
            "text/plain": [
              "0    [[0.05031391, 0.17522666, 0.71465725, 0.5769979, 0.32069182, -0.17807129, 1.2392216, -0.37865084, 0.1199767, 0.2758575, -0.002445519, 0.3054453, -0.11039174, 0.56973076, 0.120820425, -0.107291855, -0.17624098, 0.23657487, -0.23213816, 0.33558795,...\n",
              "1    [[-0.068268515, 0.042960383, 0.17118096, 0.26986143, 0.112031415, -0.20294413, 0.7771517, -0.25849432, 0.59284496, 0.6635877, 0.3940065, -0.09514284, -0.089514874, 0.33704883, 0.2717219, -0.18564875, 0.1500851, 1.5225036, -0.21757159, 0.2978152, ...\n",
              "2    [[-0.09599008, 0.03724689, 0.10206425, 0.4240935, 0.13334917, -0.043432925, 1.1233978, -0.24416606, 0.57163686, 0.4496103, -0.05453084, -0.060560953, -0.04965468, -0.28201678, 0.32567152, -0.12495111, -0.051384494, 1.0094256, -0.15498431, 0.43008...\n",
              "3    [[-0.012918322, -0.020504545, 0.4435106, 0.19794388, 0.076883316, -0.21038833, 0.5508412, -0.16301246, 0.53401446, 0.48718905, 0.5478626, 0.13116859, -0.024213262, 0.0022163023, 0.28197163, -0.17161314, 0.30555886, 0.1917058, -0.40395558, 0.17525...\n",
              "4    [[-0.10778567, 0.072568424, 0.6073649, -0.20827225, 0.17934273, -0.042293325, 0.39158764, -0.32003152, 0.3331981, 0.48051676, -0.10623282, 0.5591209, -0.18354987, 0.28779644, 0.28494167, 0.008892038, 0.57379186, 0.88093156, -0.15870328, 0.1819411...\n",
              "Name: Q_FFNN_embeds, dtype: object"
            ]
          },
          "metadata": {
            "tags": []
          },
          "execution_count": 22
        }
      ]
    },
    {
      "metadata": {
        "id": "kewyZq5JwkO9",
        "colab_type": "code",
        "colab": {}
      },
      "cell_type": "code",
      "source": [
        "def AgetEmbeds(x):\n",
        "    qt = x['question_bert']\n",
        "    at = x['answer_bert']\n",
        "    qtn = np.fromstring(\n",
        "                               qt.replace('\\n','')\n",
        "                                .replace('[','')\n",
        "                                .replace(']','')\n",
        "                                .replace('  ',' '), sep=' ')\n",
        "    atn = np.fromstring(\n",
        "                               at.replace('\\n','')\n",
        "                                .replace('[','')\n",
        "                                .replace(']','')\n",
        "                                .replace('  ',' '), sep=' ')\n",
        "    textinput = tf.constant([qtn, atn])\n",
        "    textinputF = tf.dtypes.cast(textinput , dtype=tf.float32) \n",
        "    textinputE = tf.expand_dims(textinputF, 0)\n",
        "#     trythis = medical_qa_model(textinputE)\n",
        "    q_embedding, a_embedding = tf.unstack(medical_qa_model(textinputE), axis=1)\n",
        "    return a_embedding.numpy()"
      ],
      "execution_count": 0,
      "outputs": []
    },
    {
      "metadata": {
        "id": "1d8XAW5gwrbK",
        "colab_type": "code",
        "colab": {}
      },
      "cell_type": "code",
      "source": [
        "askDocspd['A_FFNN_embeds'] = askDocspd.apply(AgetEmbeds, axis=1)"
      ],
      "execution_count": 0,
      "outputs": []
    },
    {
      "metadata": {
        "id": "SXCw9JDEwyWW",
        "colab_type": "code",
        "outputId": "89212574-fe78-466e-8ea7-37eee67afe4d",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 138
        }
      },
      "cell_type": "code",
      "source": [
        "askDocspd['A_FFNN_embeds'].head()"
      ],
      "execution_count": 0,
      "outputs": [
        {
          "output_type": "execute_result",
          "data": {
            "text/plain": [
              "0    [[-0.09869906, 0.20935602, -0.42185766, -0.33665547, 0.48797682, -0.007028032, 0.07065214, -0.16578242, -0.26237178, 0.24004409, -0.22438423, 0.18115889, 0.4567215, -0.02180059, 0.14635685, 0.74769473, -0.026884364, -0.2658844, 0.35665464, 0.3084...\n",
              "1    [[0.02158143, -0.082602814, -0.17985626, -0.19048187, 0.022836702, -0.09730069, 0.3418817, -0.15769783, -0.10843049, 0.15295486, 0.18546492, 0.09176144, 0.64303726, 0.27884188, 0.041989554, 0.09366697, 0.1290735, -0.11779204, 0.46386075, 0.239391...\n",
              "2    [[-0.16730975, 0.06444351, 0.009257315, 0.13030894, 0.1986657, 0.111179024, 0.050693758, -0.2810906, -0.16696753, 0.22874801, 0.060951676, 0.024106182, 0.10953758, -0.14491685, 0.23797303, 0.14848688, -0.06242373, -0.3347124, 0.35131043, 0.427723...\n",
              "3    [[-0.06909141, -0.11909217, -0.2177947, -0.31697032, 0.045378305, 0.26905084, 0.2377099, -0.05351404, -0.14071696, 0.2628327, 0.056118537, -0.07538253, 0.8720115, -0.14583397, 0.07096485, 0.5082699, 0.21771231, -0.33978415, 0.3260417, 0.27947804,...\n",
              "4    [[0.11793654, 0.3220811, -0.26831508, -0.3226437, 0.24534544, 0.12237222, -0.06575933, -0.31571254, -0.40923232, 0.35130405, -0.117886476, -0.11570231, 0.7159771, 0.14493895, -0.055149883, 1.7910986, 0.090899386, -0.27257594, -0.0984668, 0.167966...\n",
              "Name: A_FFNN_embeds, dtype: object"
            ]
          },
          "metadata": {
            "tags": []
          },
          "execution_count": 26
        }
      ]
    },
    {
      "metadata": {
        "id": "837XFKfw3yGU",
        "colab_type": "code",
        "outputId": "1dcb3b5d-01d6-42a5-d759-053d1b724a57",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 5343
        }
      },
      "cell_type": "code",
      "source": [
        "askDocspd.head(20)"
      ],
      "execution_count": 0,
      "outputs": [
        {
          "output_type": "execute_result",
          "data": {
            "text/html": [
              "<div>\n",
              "<style scoped>\n",
              "    .dataframe tbody tr th:only-of-type {\n",
              "        vertical-align: middle;\n",
              "    }\n",
              "\n",
              "    .dataframe tbody tr th {\n",
              "        vertical-align: top;\n",
              "    }\n",
              "\n",
              "    .dataframe thead th {\n",
              "        text-align: right;\n",
              "    }\n",
              "</style>\n",
              "<table border=\"1\" class=\"dataframe\">\n",
              "  <thead>\n",
              "    <tr style=\"text-align: right;\">\n",
              "      <th></th>\n",
              "      <th>question</th>\n",
              "      <th>answer</th>\n",
              "      <th>question_bert</th>\n",
              "      <th>answer_bert</th>\n",
              "      <th>Q_FFNN_embeds</th>\n",
              "      <th>A_FFNN_embeds</th>\n",
              "    </tr>\n",
              "  </thead>\n",
              "  <tbody>\n",
              "    <tr>\n",
              "      <th>0</th>\n",
              "      <td>Trying to get y friend to see a doctor but she wants to wait and see what happens. I'm worried sick and would like to know hat she might haveMy friend found a dime sized red lump a bit to the right of her clitoris in the shower this morning. its ...</td>\n",
              "      <td>This is most likely a Bartholin's Gland Cyst. On either side of the labia majora is a called a Bartholin's gland. Occasionally the ducts that empty the gland can become blocked causing the gland to develop a cyst. Sometimes they can go away on th...</td>\n",
              "      <td>[[ 5.03139086e-02  1.75226659e-01 -1.97714433e-01 -7.32559934e-02\\n   3.20691824e-01 -1.78071290e-01  2.48940829e-02 -3.78650844e-01\\n  -3.47410381e-01  2.75857508e-01 -2.56084532e-01  2.22180486e-01\\n  -1.10391743e-01  1.29870668e-01  1.20820425...</td>\n",
              "      <td>[[-9.86990631e-02  2.09356025e-01 -4.21857655e-01 -3.36655468e-01\\n   4.87976819e-01 -7.02803209e-03 -3.16477306e-02 -1.65782422e-01\\n  -2.62371778e-01  2.40044087e-01 -2.24384233e-01  1.41379043e-01\\n   1.54396653e-01 -2.18005907e-02  1.46356851...</td>\n",
              "      <td>[[0.05031391, 0.17522666, 0.71465725, 0.5769979, 0.32069182, -0.17807129, 1.2392216, -0.37865084, 0.1199767, 0.2758575, -0.002445519, 0.3054453, -0.11039174, 0.56973076, 0.120820425, -0.107291855, -0.17624098, 0.23657487, -0.23213816, 0.33558795,...</td>\n",
              "      <td>[[-0.09869906, 0.20935602, -0.42185766, -0.33665547, 0.48797682, -0.007028032, 0.07065214, -0.16578242, -0.26237178, 0.24004409, -0.22438423, 0.18115889, 0.4567215, -0.02180059, 0.14635685, 0.74769473, -0.026884364, -0.2658844, 0.35665464, 0.3084...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>1</th>\n",
              "      <td>Ease my worries pleaseMy husband is about to see a hematologist and googling around has me worried that he's got something serious, like aplastic anemia. I know we'll find out soon enough, but in the meantime, could you please suggest alternative...</td>\n",
              "      <td>Would be helpful with the exact values of the CBC. And B12, Folate and Ferritin values.\\n\\nAre liver and kidney function tests okay?\\n\\nWhat are his ethnic origins?,Is he diabetic. Does he take any other medication?,Does he take aspirin?\\nDid he ...</td>\n",
              "      <td>[[-6.82685152e-02  4.29603830e-02 -3.32764566e-01 -6.10484481e-02\\n   1.12031415e-01 -2.02944130e-01 -9.14147869e-02 -2.58494318e-01\\n  -2.18344301e-01  2.87112653e-01 -6.67973831e-02 -9.51428413e-02\\n  -8.95148739e-02 -1.64768383e-01  2.71721900...</td>\n",
              "      <td>[[ 2.15814300e-02 -8.26028138e-02 -1.79856256e-01 -1.90481871e-01\\n   2.28367019e-02 -9.73006934e-02 -1.17688790e-01 -1.57697827e-01\\n  -1.08430490e-01  1.52954862e-01  1.85464919e-01 -1.62801355e-01\\n   2.00268812e-02 -2.12160777e-02  4.19895537...</td>\n",
              "      <td>[[-0.068268515, 0.042960383, 0.17118096, 0.26986143, 0.112031415, -0.20294413, 0.7771517, -0.25849432, 0.59284496, 0.6635877, 0.3940065, -0.09514284, -0.089514874, 0.33704883, 0.2717219, -0.18564875, 0.1500851, 1.5225036, -0.21757159, 0.2978152, ...</td>\n",
              "      <td>[[0.02158143, -0.082602814, -0.17985626, -0.19048187, 0.022836702, -0.09730069, 0.3418817, -0.15769783, -0.10843049, 0.15295486, 0.18546492, 0.09176144, 0.64303726, 0.27884188, 0.041989554, 0.09366697, 0.1290735, -0.11779204, 0.46386075, 0.239391...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>2</th>\n",
              "      <td>Severe shoulder, neck and back pain after tetanus vaccinationA little less than a week ago I received my tetanus booster shot (the one you receive every decade, at least here in Australia).\\n\\nA few days later I began experiencing pain around my ...</td>\n",
              "      <td>I seriously don't think your pain derives from the vaccination.\\n\\nIt looks like trapezoid contracture (is it the right word in english?).\\n\\nHeat and posture care should help you, elseways some muscular relaxant could be helpful.\\n\\nAnyways, at ...</td>\n",
              "      <td>[[-9.59900767e-02  3.72468904e-02 -3.78887504e-01 -4.50596698e-02\\n   1.33349165e-01 -4.34329249e-02  4.04662602e-02 -2.44166061e-01\\n  -1.02068119e-01  4.49610293e-01 -5.45308404e-02 -8.46140832e-02\\n  -4.96546812e-02 -2.82016784e-01  3.25671524...</td>\n",
              "      <td>[[-1.67309746e-01  6.44435063e-02  9.25731473e-03  1.30308941e-01\\n   1.98665693e-01  1.11179024e-01  3.86667326e-02 -2.81090587e-01\\n  -1.66967526e-01  2.28748009e-01  6.09516762e-02  2.41061822e-02\\n   2.80033629e-02 -1.44916847e-01  2.37973034...</td>\n",
              "      <td>[[-0.09599008, 0.03724689, 0.10206425, 0.4240935, 0.13334917, -0.043432925, 1.1233978, -0.24416606, 0.57163686, 0.4496103, -0.05453084, -0.060560953, -0.04965468, -0.28201678, 0.32567152, -0.12495111, -0.051384494, 1.0094256, -0.15498431, 0.43008...</td>\n",
              "      <td>[[-0.16730975, 0.06444351, 0.009257315, 0.13030894, 0.1986657, 0.111179024, 0.050693758, -0.2810906, -0.16696753, 0.22874801, 0.060951676, 0.024106182, 0.10953758, -0.14491685, 0.23797303, 0.14848688, -0.06242373, -0.3347124, 0.35131043, 0.427723...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>3</th>\n",
              "      <td>Knee problemHere's the run down.  This past weekend my wife and I took part in a 3-day walk for breast cancer.  It was 60 miles, so clearly a lot of work on my knees.  Day 1 went fine, feet hurt, but to be expected.  Day two came and I was having...</td>\n",
              "      <td>It's possible that you caused some damage while playing sports and now with a heavy amount of activity caused aggravation of that injury. Its possible to cause a small tear in a meniscus and go years without any problems until a specific event ca...</td>\n",
              "      <td>[[-1.29183223e-02 -2.05045454e-02 -5.12924075e-01 -1.66846707e-01\\n   7.68833160e-02 -2.10388333e-01 -1.76014677e-01 -1.63012460e-01\\n  -2.01517850e-01  4.29517597e-01 -5.23534641e-02  1.08745629e-02\\n  -2.42132619e-02  2.21630232e-03  2.81971633...</td>\n",
              "      <td>[[-6.90914094e-02 -1.75325274e-01 -2.17794701e-01 -3.16970319e-01\\n   4.53783050e-02  2.69050837e-01 -8.84563774e-02 -5.35140410e-02\\n  -1.40716955e-01  2.62832701e-01  5.61185367e-02 -7.53825307e-02\\n  -3.30312178e-03 -1.45833969e-01  7.09648505...</td>\n",
              "      <td>[[-0.012918322, -0.020504545, 0.4435106, 0.19794388, 0.076883316, -0.21038833, 0.5508412, -0.16301246, 0.53401446, 0.48718905, 0.5478626, 0.13116859, -0.024213262, 0.0022163023, 0.28197163, -0.17161314, 0.30555886, 0.1917058, -0.40395558, 0.17525...</td>\n",
              "      <td>[[-0.06909141, -0.11909217, -0.2177947, -0.31697032, 0.045378305, 0.26905084, 0.2377099, -0.05351404, -0.14071696, 0.2628327, 0.056118537, -0.07538253, 0.8720115, -0.14583397, 0.07096485, 0.5082699, 0.21771231, -0.33978415, 0.3260417, 0.27947804,...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>4</th>\n",
              "      <td>Had a strange experience last night.Woke up in the middle of the night to take a leak. As I flushed the toilet I remember standing there feeling very light headed. I turned around and started to walk back to bed but never made it. Apparently I pa...</td>\n",
              "      <td>Sounds like you had an episode of positional hypotension leading to syncope, or in other words, you stood up too fast causing a drop in blood pressure which made you pass out. If this was a one time thing you don't need to worry about it. Its pos...</td>\n",
              "      <td>[[-1.07785672e-01  7.25684240e-02 -3.21571469e-01 -3.26673627e-01\\n   1.79342732e-01 -4.22933251e-02 -4.46543284e-02 -3.20031524e-01\\n  -3.15706164e-01  4.07414287e-01 -2.55068183e-01 -8.69708136e-02\\n  -1.83549866e-01  6.94538057e-02  2.84941673...</td>\n",
              "      <td>[[ 1.17936537e-01  3.22081089e-01 -2.68315077e-01 -3.22643697e-01\\n   2.45345443e-01  1.22372217e-01 -6.57593310e-02 -3.15712541e-01\\n  -4.09232318e-01  3.51304054e-01 -1.17886476e-01 -1.15702309e-01\\n  -1.23623818e-01  5.74846864e-02 -5.51498830...</td>\n",
              "      <td>[[-0.10778567, 0.072568424, 0.6073649, -0.20827225, 0.17934273, -0.042293325, 0.39158764, -0.32003152, 0.3331981, 0.48051676, -0.10623282, 0.5591209, -0.18354987, 0.28779644, 0.28494167, 0.008892038, 0.57379186, 0.88093156, -0.15870328, 0.1819411...</td>\n",
              "      <td>[[0.11793654, 0.3220811, -0.26831508, -0.3226437, 0.24534544, 0.12237222, -0.06575933, -0.31571254, -0.40923232, 0.35130405, -0.117886476, -0.11570231, 0.7159771, 0.14493895, -0.055149883, 1.7910986, 0.090899386, -0.27257594, -0.0984668, 0.167966...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>5</th>\n",
              "      <td>Can anyone identify this?My 22 month old woke up with this.  We immediately took him to urgent care and they literally used the word, \"perplexed\" . We are waiting on an appointment on Monday. Any ideas would be helpful.</td>\n",
              "      <td>It almost looks like prolonged exposure to something very hot. I'm not too sure what else it could be. Best of luck to you and your baby!,Yeah, my first thought was burning lesions, too.\\nThe other DD could be some pemphigoid lesion, but the skin...</td>\n",
              "      <td>[[-1.80355459e-01  9.13417861e-02 -2.31477898e-02  1.68505371e-01\\n   3.64697009e-01 -2.84921029e-03  5.26331700e-02 -2.32272148e-01\\n  -2.76783496e-01  1.85831234e-01 -1.82725415e-01 -2.45477608e-03\\n  -5.56782305e-01  2.07249716e-01  4.03501727...</td>\n",
              "      <td>[[-8.75879154e-02  2.78869659e-01  7.62948021e-03 -1.34483024e-01\\n   2.21360382e-02  1.17703408e-01  1.85167156e-02 -2.49677420e-01\\n  -2.66380191e-01  1.92860708e-01 -2.41361745e-02  1.67692788e-02\\n  -2.19728127e-01 -3.16680670e-02  6.96710646...</td>\n",
              "      <td>[[-0.18035546, 0.091341786, 0.14185199, 0.26876837, 0.364697, -0.0028492103, 0.05263317, -0.23227215, 0.63868487, 0.459853, 0.3550713, 0.11367951, -0.5567823, 0.37561405, 0.040350173, -0.15050356, -0.09284662, -0.20346472, 0.07705624, 0.35358286,...</td>\n",
              "      <td>[[-0.087587915, 0.27886966, 0.00762948, -0.13448302, 0.022136038, 0.11770341, 0.018516716, -0.24967742, -0.2663802, 0.43704742, -0.024136174, 0.016769279, -0.21972813, 0.099903345, 0.069671065, 0.35788065, 0.19415134, -0.3672943, 0.0820634, 0.321...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>6</th>\n",
              "      <td>Bite, ingrown hair, infection?* [one](http://imgur.com/3901epB)\\n* [two](http://imgur.com/9w1QWlY)\\n* [three](http://imgur.com/TVDxF0H)\\n\\nAny idea what these are? The one on my cheek started off as a small scab (maybe a zit or something). I defi...</td>\n",
              "      <td>The ones in the beard look like Tinea, a fungal infection. \\nAnd I bet that the bigger one is also fungal, but made worse by scratching.\\n\\nYou should go to a GP for some anti fungal ointment...</td>\n",
              "      <td>[[-4.58974428e-02  1.85957506e-01 -3.29710752e-01 -2.30540082e-01\\n  -3.92941460e-02 -8.59922394e-02 -2.67444197e-02 -2.28515729e-01\\n   2.24398915e-02  2.30619475e-01 -1.23537935e-01  2.24547207e-01\\n  -3.28298435e-02 -9.60415080e-02 -4.08210233...</td>\n",
              "      <td>[[-8.41102079e-02  1.84079811e-01 -8.89919475e-02 -2.76612118e-02\\n   2.09251344e-01  2.61974871e-01  9.31475013e-02 -3.65237713e-01\\n  -3.54500890e-01  2.28741035e-01 -8.78387317e-02  2.49303564e-01\\n  -2.21121296e-01  4.75698560e-02  1.38536990...</td>\n",
              "      <td>[[-0.045897443, 0.1859575, 0.79868317, 0.4142545, -0.039294146, -0.08599224, 0.92267793, -0.22851573, 0.56371015, 0.31517312, 0.77103704, 0.24593458, -0.032829843, 0.49358177, -0.040821023, 0.039925233, -0.23192735, 0.19133624, -0.45759693, 0.062...</td>\n",
              "      <td>[[-0.08411021, 0.18407981, -0.08899195, -0.027661212, 0.20925134, 0.26197487, 0.0931475, -0.3652377, -0.3545009, 0.22874103, -0.05313527, 0.24930356, -0.21285923, 0.047569856, 0.13853699, 1.0090455, -0.08114073, -0.19877541, -0.15805234, 0.389106...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>7</th>\n",
              "      <td>Busted my lip and need advice on how to heal it properly!I fell off my bike and busted my lip. I got four stitches on the inside, and just scratches on the outside. It is quite swollen and hard. I am hoping to get some advice on how make it heal ...</td>\n",
              "      <td>Wash and wait.\\nTime is the only factor here.</td>\n",
              "      <td>[[ 4.99398075e-02  1.20460384e-01 -6.29447773e-02 -1.55243874e-01\\n  -1.44786581e-01 -2.17289880e-01  6.88850507e-02 -1.41801581e-01\\n  -9.79681034e-03  1.61795571e-01 -1.72716439e-01  2.97343414e-02\\n   1.00814886e-01  3.40392068e-02 -1.29933372...</td>\n",
              "      <td>[[ 3.61181676e-01  9.27573293e-02 -2.03941107e-01  3.56207043e-01\\n   4.41465884e-01 -2.86622703e-01  4.93434727e-01 -2.53519654e-01\\n  -4.14035097e-02 -1.14065088e-01 -5.41325927e-01  4.32440013e-01\\n   1.31187424e-01  4.03006256e-01 -7.08923340...</td>\n",
              "      <td>[[0.049939808, 0.12046038, 0.61080974, 0.10166994, -0.14478658, -0.21728988, 1.2853746, -0.14180158, -0.00979681, 0.16179557, 0.2864955, 0.87758493, 0.10081489, 0.25402442, -0.12993337, 0.1418176, -0.2160801, -0.046122134, -0.31051943, 0.19090335...</td>\n",
              "      <td>[[0.36118168, 0.53679043, 0.09158689, 0.35620704, 0.8140732, -0.2866227, 0.49343473, -0.25351965, -0.04140351, -0.11406509, -0.5413259, 0.550707, 0.13118742, 0.40300626, -0.070892334, -0.1997576, 0.60152066, 0.44648597, -0.07755573, 0.65332866, 0...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>8</th>\n",
              "      <td>Just needed to know if this is \"normal\"- and ideally, why.The last 6-9 months, my (F,35) lymph nodes in my armpits painfully swell up about once a month, take about a week to go back to normal. When it first started happening, I went to an urgent...</td>\n",
              "      <td>This can be normal. This is happening every month, does it coincide with your medstrual cycle? Painful lymph nodes are nothing to worry about. This can happen with you have changes in hormones, when your body is trying to fight infections, etc. L...</td>\n",
              "      <td>[[ 1.09046437e-02  2.51035661e-01 -4.12880450e-01 -7.29131326e-02\\n  -3.01259682e-02  2.62525789e-02 -3.98364812e-02 -2.58315384e-01\\n  -2.89434969e-01  1.66334078e-01  6.32746443e-02 -2.08434202e-02\\n  -4.90285046e-02 -1.26866013e-01  2.41994068...</td>\n",
              "      <td>[[-5.89954145e-02  9.62038636e-02 -1.60867006e-01 -2.52489001e-01\\n  -1.09475821e-01  6.57585487e-02 -3.30365486e-02 -3.27971756e-01\\n  -2.58334517e-01  1.66886181e-01  1.31579293e-02  2.67492924e-02\\n   1.93602532e-01  1.12057813e-01  2.15599194...</td>\n",
              "      <td>[[0.010904644, 0.25103566, 0.13396052, 0.4604362, -0.030125968, 0.026252579, 0.6074764, -0.25831538, 0.34907365, 0.49096107, 0.46270916, 0.30601597, -0.049028505, 0.11198901, 0.24199407, -0.12763695, 0.0048868647, 0.40711734, -0.3820984, 0.378389...</td>\n",
              "      <td>[[-0.058995415, 0.09620386, -0.160867, -0.252489, -0.10947582, 0.06575855, 0.3831236, -0.32797176, -0.25833452, 0.16688618, 0.013157929, 0.23609565, 0.80914056, 0.25079644, 0.2155992, 1.3976666, 0.07401086, -0.22676554, -0.05611816, 0.37811735, -...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>9</th>\n",
              "      <td>I've created a collection of amino acids and supplements that could potentially increase my release of HGH to 2000%-4000% what could be the consequences of executing this?I am under 18, so my plates have not yet closed.</td>\n",
              "      <td>You would develop Acromegaly, also known as Gigantism. It would have drastic effects on bone growth, fertility, muscle development, and several hormonal regulating systems in your body like sugar balance and insulin. You can check out the Wikiped...</td>\n",
              "      <td>[[-8.31616744e-02  3.04023921e-01 -1.18793786e-01  1.61059380e-01\\n   1.25026569e-01 -2.26919770e-01  2.46555969e-01 -1.52935982e-01\\n  -2.75091082e-01  2.29911387e-01  6.95227832e-02  2.77909953e-02\\n  -2.28861675e-01 -8.43423828e-02  1.35876536...</td>\n",
              "      <td>[[-1.76602155e-01  6.17301278e-02 -6.11533299e-02 -1.70265079e-01\\n  -1.04844943e-01 -1.67983010e-01  1.36407509e-01 -2.09834725e-01\\n   8.97120684e-02  6.27892911e-02 -2.77223855e-01  1.51995748e-01\\n   3.47727656e-01 -1.78699754e-02 -4.71802324...</td>\n",
              "      <td>[[-0.083161674, 0.30402392, 0.9112342, 0.16105938, 0.1272867, -0.22691977, 0.8712962, -0.15293598, 0.2285243, 0.69513017, 0.06952278, 0.027790995, -0.22886167, -0.08434238, 0.13587654, -0.21821095, -0.028593391, -0.040001836, 0.06398056, 0.233339...</td>\n",
              "      <td>[[-0.17660215, 1.2277203, -0.06115333, -0.17026508, 1.0580376, -0.16798301, 0.24272121, -0.20983472, 0.08971207, 0.6569524, -0.27722386, 0.4281262, 0.48739827, 0.2324163, -0.47180232, -0.18792889, -0.19671606, -0.57597274, 0.12601036, 0.44215077,...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>10</th>\n",
              "      <td>Accidentally took 2 doses of tecta?I'm supposed to take 40mg of tecta daily, but I accidentally took it twice so I took 80mg in total, is that OK?</td>\n",
              "      <td>yes, you will be fine.</td>\n",
              "      <td>[[-1.12157948e-01  4.43421781e-01 -2.27056161e-01  4.38472569e-01\\n   6.23993397e-01 -2.34182894e-01  3.34971458e-01 -1.92059025e-01\\n  -3.90465975e-01  2.35055134e-01  7.78263062e-02 -5.02863303e-02\\n  -4.39123243e-01  1.31034389e-01  4.63932425...</td>\n",
              "      <td>[[ 6.88412189e-02  2.50665486e-01  1.33473709e-01  2.63651192e-01\\n  -2.29095384e-01  2.68963486e-01  3.97941440e-01 -3.45116228e-01\\n  -2.56032646e-01 -1.50789842e-01  6.33369684e-02 -1.57825381e-01\\n   1.31796360e-01  1.03793032e-01 -1.89787194...</td>\n",
              "      <td>[[-0.11215795, 0.44342178, -0.22705616, 0.9130324, 0.6239934, -0.2341829, 0.99952507, -0.19205903, -0.39046597, 0.23505513, 0.89798194, -0.05028633, -0.43912324, 0.13103439, 0.46393242, -0.18600073, 0.46653593, 0.5945296, -0.09542866, 1.002146, 0...</td>\n",
              "      <td>[[0.06884122, 0.3991459, 0.13347371, 1.2714124, 0.4602924, 0.2689635, 0.4293988, -0.34511623, -0.07977429, -0.15078984, 0.1119453, -0.15782538, 0.13179636, 0.10379303, -0.1897872, 0.073030375, -0.048009794, -0.22115533, -0.16689084, 1.2068557, -0...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>11</th>\n",
              "      <td>Brian hemorrhage mother in ICU: Want to know if these things are normal.My mother suffered from a Subarachnoid hemorrhage stroke (SAH) on 1/9/15. She had an aneurysm rupture behind her left eye. She has been in the ICU this whole time. Some info:...</td>\n",
              "      <td>&amp;gt;4) Is it possible for TCD (transcranial doppler) and CAT scans to be wrong about vasospasms? \\n\\nSure, angiograms are still the gold standard. The evidence for the treatment of vasospasms in limited by the way, we do not no for sure if these ...</td>\n",
              "      <td>[[-2.29815200e-01 -2.73736473e-02 -3.96248132e-01 -1.15639813e-01\\n   4.00952473e-02 -1.44953832e-01 -1.33097336e-01 -2.18443498e-01\\n  -1.83913395e-01  4.09907192e-01 -5.54141030e-02  1.51335225e-01\\n  -3.08908634e-02 -7.50564784e-02  1.65862992...</td>\n",
              "      <td>[[ 1.06997713e-01  1.39075860e-01 -1.63705066e-01  3.04865420e-01\\n   3.85065556e-01 -7.77797028e-02 -5.99039756e-02 -3.22348833e-01\\n  -7.88318068e-02  4.58603688e-02 -2.27341056e-01 -2.92531729e-01\\n  -1.09925605e-01  1.62464947e-01 -1.13994867...</td>\n",
              "      <td>[[-0.2298152, -0.027373647, 0.2343978, 0.118794404, 0.040095247, -0.14495383, 0.55689496, -0.2184435, 0.4118657, 0.84105134, -0.022418566, 0.15133522, -0.030890863, 0.54792094, 0.16586299, 0.00252006, 0.4403717, 0.46651894, -0.19945136, 0.2714683...</td>\n",
              "      <td>[[0.10699771, 0.13907586, -0.16370507, 0.30486542, 0.4369713, -0.0777797, -0.0005571209, -0.32234883, -0.07883181, 0.04586037, -0.22734106, 0.11739552, 1.2917163, 0.50037754, -0.11399487, -0.027811646, 0.33034086, -0.1898757, -0.18361315, 0.08811...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>12</th>\n",
              "      <td>Solutions or Treatments for Simulator Sickness\\nGeneral question:\\nMy fiance has some issues with Simulator sickness. We've tried some solutions such as siting further back from the screen or changing the field of view for games or movies, but to...</td>\n",
              "      <td>There are other non-antihistaminic treatments for motion sickness, I would guess I would try these (like scopolamine). I do would want to discuss the risk/benefit ratio for using drugs to enjoy certain games.</td>\n",
              "      <td>[[-6.76830411e-02  2.11186498e-01 -3.51235420e-01  1.34276643e-01\\n  -3.78634445e-02 -1.99097946e-01 -4.19404991e-02 -7.24120997e-03\\n  -1.95001751e-01  7.00763911e-02 -1.31977037e-01  8.68828669e-02\\n  -2.35166326e-01  5.46145998e-02 -1.56805858...</td>\n",
              "      <td>[[-1.32732004e-01  6.73507228e-02 -1.56957269e-01  8.61029401e-02\\n  -8.40305239e-02 -2.15575442e-01  1.22828379e-01 -8.41380954e-02\\n  -5.01216240e-02 -8.34617987e-02 -2.05751881e-01  4.20058295e-02\\n  -1.55402228e-01  2.09729657e-01 -9.05604661...</td>\n",
              "      <td>[[-0.06768304, 0.2111865, 1.33728, 0.4093728, -0.037863445, -0.19909795, 0.59675986, -0.00724121, 1.2763453, 0.8271443, -0.050741434, 0.08688287, -0.23516633, 1.263954, -0.15680586, -0.090711355, 0.40230146, -0.109419316, -0.11487891, 0.41448542,...</td>\n",
              "      <td>[[-0.132732, 0.79169184, -0.15695727, 0.08610294, -0.084030524, -0.21557544, 0.43121457, -0.05919546, -0.050121624, 0.116889946, 0.16201825, 0.14344037, 0.22812246, 0.20972966, -0.009056047, -0.06952244, 0.17648898, 0.33555833, -0.22924715, 0.138...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>13</th>\n",
              "      <td>Should I be worried about my swollen lymph nodes?I'm a 17 y/o white F, 5 foot 1 and 118 pounds. For a little more than a week the lymph nodes in my left armpit have been swollen and painful both when touched and left on their own. In the past wee...</td>\n",
              "      <td>I think this warrants a trip to your doctor.</td>\n",
              "      <td>[[-1.00367039e-01  1.71976656e-01 -3.27672809e-01 -1.25366449e-01\\n   2.28840232e-01 -1.99621424e-01  3.30793262e-02 -3.98666710e-01\\n  -2.62436420e-01  3.04824293e-01 -7.64185041e-02  1.63578838e-01\\n  -2.59301299e-03 -5.35064302e-02  3.54401350...</td>\n",
              "      <td>[[ 1.53559282e-01  1.29343063e-01  1.96472570e-01  5.89777417e-02\\n  -3.78266871e-02  4.09878120e-02  4.34025019e-01 -4.41730499e-01\\n  -1.51526034e-01 -1.98788866e-01  8.50769654e-02 -1.79388821e-01\\n   2.52134532e-01 -1.64774403e-01  2.96966136...</td>\n",
              "      <td>[[-0.10036704, 0.17197666, 0.6682855, -0.06802086, 0.22884023, -0.19962142, 0.55211335, -0.3986667, 0.6215303, 0.5883613, 0.56345475, 0.7833128, -0.002593013, 0.41028988, 0.35440135, -0.09089787, -0.038822114, 0.9048873, -0.11726918, 0.41297364, ...</td>\n",
              "      <td>[[0.15355928, 0.9022887, 0.19647257, 0.05897774, -0.037826687, 0.040987812, 0.65439725, -0.4417305, -0.15152603, -0.13688846, 0.085076965, 0.09020758, 1.3557999, -0.1647744, 0.29696614, -0.06793762, -0.16783336, 0.042502217, -0.113421805, 1.49819...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>14</th>\n",
              "      <td>My partner is a designate female and I also am female She keeps having OrgasmsApparently the average woman doesn't have Orgasms and I'm wondering if this amount of orgasms she has is in excess. I also have Orgasms.</td>\n",
              "      <td>&amp;gt;Apparently the average woman doesn't have Orgasms \\n\\nThat isn't true.\\n\\n&amp;gt;I'm wondering if this amount of orgasms she has is in excess\\n\\nExcess orgasms? What?</td>\n",
              "      <td>[[-2.51177996e-01  3.63571227e-01  3.47003564e-02 -2.08076998e-03\\n   3.20553362e-01  5.85481850e-03  3.72257084e-01 -5.54251730e-01\\n  -3.58152896e-01  1.61806028e-02  9.18404534e-02  1.79168910e-01\\n  -7.55692422e-02  2.79023618e-01  1.72599107...</td>\n",
              "      <td>[[-2.91481555e-01  4.76583719e-01 -4.21611182e-02  2.23754078e-01\\n   1.99215516e-01 -9.85787287e-02  4.28873539e-01 -5.40630281e-01\\n  -2.82934368e-01  5.40661216e-02  1.92386284e-02  2.64240295e-01\\n   1.13377452e-01  3.98269072e-02  1.86027139...</td>\n",
              "      <td>[[-0.251178, 0.36357123, 0.19599599, 0.4916827, 0.32055336, 0.0058548185, 0.58947575, -0.55425173, -0.35607582, 1.0378833, 0.64087886, 1.6529472, -0.07556924, 0.61150223, 0.1725991, -0.0116100665, 0.20288852, 0.7131314, -0.12291423, 0.37912995, -...</td>\n",
              "      <td>[[-0.29148155, 0.47658372, -0.04216112, 0.22375408, 0.19921552, -0.09857873, 0.42887354, -0.5406303, -0.28293437, 0.88321656, 0.019238628, 0.2642403, 0.8570628, 0.07455567, 0.18602714, 1.9101144, 0.122920565, -0.040849674, 0.18245947, 0.47146246,...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>15</th>\n",
              "      <td>24f. Chest pain lasting hours, getting worse. What do I do?I am a 24 year-old female. I have been experiencing chest pain off and on for a few weeks. It's mostly in or around my ribs under my breasts. It feels like a pressure. It is not necessari...</td>\n",
              "      <td>I would need much more information and i would actually want to see you to tell you anything other than go to the ER if you feel its serious. If the problem resolves itself defiantly call your primary care doc and talk to them. \\n  does the pain ...</td>\n",
              "      <td>[[-6.24945434e-03  1.23614438e-01 -3.61742765e-01 -2.03729138e-01\\n   2.37937406e-01 -1.22119091e-01 -8.30616280e-02 -3.95189911e-01\\n  -1.48478165e-01  3.74310017e-01 -2.12274566e-01  1.55362904e-01\\n  -3.24470364e-02 -6.42820299e-02  2.01565623...</td>\n",
              "      <td>[[ 9.48783159e-02 -1.29473612e-01 -4.10793312e-02 -2.53820181e-01\\n   2.60319352e-01  1.28168270e-01 -1.11271478e-01 -5.47138713e-02\\n  -2.53896177e-01  3.35424989e-01  5.38754882e-03 -1.34149557e-02\\n   4.28323913e-03 -1.43202856e-01  2.61246741...</td>\n",
              "      <td>[[-0.0062494543, 0.12361444, 0.59349835, 0.025204405, 0.2379374, -0.12211909, 0.5145799, -0.3951899, 1.1732261, 0.699885, -0.21227457, 0.46315265, -0.032447036, 0.26972327, 0.20156562, -0.05767897, -0.02102714, 0.47356787, -0.21486072, 0.21103245...</td>\n",
              "      <td>[[0.094878316, -0.12947361, -0.04107933, -0.25382018, 0.26031935, 0.12816827, 0.06646284, -0.05471387, -0.25389618, 0.335425, 0.005387549, -0.013414956, 0.06603424, -0.14320286, 0.26124674, 0.78168005, -0.0045633763, -0.23666911, 0.5200337, 0.251...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>16</th>\n",
              "      <td>Gynecomastia or Breast cancer?13\\nMale\\n177cm\\n60 kg\\nAmerican/Japanese\\nAt least 6 months\\nLeft nipple of breast\\nNo medical issues\\nNo medication\\n\\nI've had this bump that changes it's size and texture every now and again for at least 6 months...</td>\n",
              "      <td>Breast cancer in a 13 year old male is tremendously rare.\\n\\nGynaecomastia can take quite a while longer than 6 months to resolve.\\n\\n</td>\n",
              "      <td>[[-3.49072888e-02  2.72150069e-01 -3.78085911e-01  9.82727110e-02\\n   1.51978344e-01 -1.00297995e-01  1.58503816e-01 -3.41629684e-01\\n  -5.50584018e-01  2.49761224e-01 -1.55945316e-01 -2.77337115e-02\\n  -3.25412862e-02 -8.08728263e-02  2.57948697...</td>\n",
              "      <td>[[-1.90779299e-01  1.72353283e-01 -1.10838704e-01  2.59033829e-01\\n   4.67246532e-01 -1.08562537e-01 -8.70064553e-03 -1.83964610e-01\\n  -1.20578162e-01  1.83340788e-01 -2.65375882e-01  2.15853944e-01\\n   2.99135804e-01  2.08692431e-01  1.04468204...</td>\n",
              "      <td>[[-0.03490729, 0.27215007, 0.51699543, 0.5875977, 0.15197834, -0.100297995, 0.3306139, -0.34162968, 0.6238052, 0.24976122, 0.15855102, -0.027733712, -0.032541286, 0.55993277, 0.2579487, -0.03114066, -0.19984771, 1.0968158, 0.027874587, 0.24369775...</td>\n",
              "      <td>[[-0.1907793, 0.8906218, -0.110838704, 0.80821145, 0.46724653, -0.10856254, 0.44675112, -0.18396461, 0.32830828, 0.18334079, -0.26537588, 0.3562675, 1.3322723, 0.32925254, 0.104468204, -0.12629494, -0.07290969, -0.2992357, 0.09363668, 0.6341158, ...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>17</th>\n",
              "      <td>Worried about heart *thumps*Age 31\\n\\nSex Male\\n\\nHeight 197cm\\n\\nWeight 180kg\\n\\nRace Caucasian\\n\\nDuration of complaint 2 days\\n\\nLocation (Geographic and on body) Heart\\n\\nAny existing relevant medical issues (if any) Type 2 diabetic\\n\\nCurren...</td>\n",
              "      <td>&amp;gt;Danish names, hope it translates\\n\\nSure, metformin and losartan.\\n\\n&amp;gt;The past couple of days about 1-2 times an hour my heart has made this \"thump\" in my chest like it is beating extra hard one time.\\n\\nThat sounds like a ventricular extr...</td>\n",
              "      <td>[[-7.61162415e-02 -2.23482531e-02 -2.50584573e-01 -8.25186539e-03\\n   8.61281753e-02 -2.20288441e-01  9.32557806e-02 -2.38561273e-01\\n  -2.53661007e-01  3.97102594e-01 -1.60614029e-01  8.40611532e-02\\n  -1.15015686e-01 -1.17804967e-01  2.35514179...</td>\n",
              "      <td>[[-9.71726552e-02  7.27577507e-02 -2.53779143e-01 -1.59242183e-01\\n   2.81454384e-01 -6.17131293e-02  2.29519438e-02 -1.79074004e-01\\n  -1.26287997e-01  2.36242399e-01 -1.87451720e-01  4.43626903e-02\\n   7.29264095e-02 -1.07286997e-01  1.76546350...</td>\n",
              "      <td>[[-0.07611624, -0.022348253, 0.751212, 0.09780994, 0.086128175, -0.22028844, 0.83830035, -0.23856127, 0.6291239, 0.3971026, -0.0152027905, 0.36427912, -0.115015686, 0.40980598, 0.23551418, -0.07058594, -0.059574872, 0.4545892, -0.1583698, 0.31147...</td>\n",
              "      <td>[[-0.097172655, 0.07275775, -0.25377914, -0.15924218, 0.28145438, -0.06171313, 0.34107372, -0.179074, -0.126288, 0.2362424, -0.18745172, 0.24850127, 0.573665, -0.0249039, 0.17654635, 0.60749644, -0.1722704, -0.3090028, 0.047246233, 0.31476793, 0....</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>18</th>\n",
              "      <td>If two members of my extended family (aunt and uncle) were diagnosed with chronic leukemia, what is my chance of getting it?I was a smoker (recently quit), i'm 19 years old and my father does not have it. Although that same aunt also had vitiligo...</td>\n",
              "      <td>To date, we have no information on the existence of inheritable types of leukemia. So your chances are probably just as low as your next door neighbours chances. ,Do you know specifically what type of leukemia it is?,As /u murpahurp said, there i...</td>\n",
              "      <td>[[-1.76481977e-01  2.84115344e-01 -1.67520121e-01  1.47998661e-01\\n   2.00637728e-01 -6.31852522e-02  2.03767970e-01 -4.42649364e-01\\n  -6.00873232e-02 -9.57488790e-02  1.15900129e-01 -2.10186560e-02\\n  -2.63529301e-01 -3.08748037e-01  1.52012542...</td>\n",
              "      <td>[[-1.59571663e-01  1.56269968e-01 -2.98799515e-01 -2.09489346e-01\\n   2.34919831e-01  3.27772908e-02  1.16240576e-01 -1.56799674e-01\\n  -9.09149460e-03 -3.49322110e-02 -8.62018615e-02  5.06505072e-02\\n  -1.09480605e-01  7.82237276e-02 -1.76918000...</td>\n",
              "      <td>[[-0.17648198, 0.28411534, 0.38130414, 0.3100694, 0.20063773, -0.03262607, 0.9389497, -0.44264936, 1.9756128, -0.09574888, 1.3066144, -0.021018656, -0.2635293, -0.27166194, 0.15201254, 0.0023924613, 1.0857308, 0.9102626, 0.2169805, 0.48707527, -0...</td>\n",
              "      <td>[[-0.15957166, 0.40267903, -0.2987995, -0.20948935, 0.23491983, 0.03277729, 0.31468588, -0.15679967, -0.009091495, -0.03493221, -0.08620186, 0.060476154, -0.066437975, 0.07822373, -0.176918, -0.2508848, 0.036230676, -0.24474354, 0.32010782, 0.410...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>19</th>\n",
              "      <td>23M getting constant mouth UlcersHi,\\n\\nI am getting mouth ulcers all the time, the current one is right on the stringy bit underneath your bottom teeth, and after using special mouthwash last night and Ulcer gel, it is horrible today.\\n\\nBeen ge...</td>\n",
              "      <td>The gum might have sodium luyrate sulphate, (SLS), it's a chemical that can cause an allergic reaction. Totally agree with stopping the gum.  If it's still persistent, speak to your doctor about aphthous-like ulcers, which can be systemic manifes...</td>\n",
              "      <td>[[-1.81584835e-01  2.42096439e-01 -2.76913613e-01  1.40295252e-01\\n   1.63019717e-01 -1.43782198e-01  1.12951100e-01 -4.03191656e-01\\n  -5.57388961e-01  3.51284325e-01  2.41640564e-02 -1.83883142e-02\\n  -2.71238834e-02 -3.55523042e-02  1.70369044...</td>\n",
              "      <td>[[-4.72920537e-02  1.69462770e-01 -1.43597782e-01 -9.65186357e-02\\n   6.95647001e-02  6.65156245e-02 -1.41030952e-01 -1.60091773e-01\\n  -1.97065473e-01  1.49176151e-01  2.97701657e-01  1.56476691e-01\\n  -6.36801049e-02 -1.30709529e-01  1.41993508...</td>\n",
              "      <td>[[-0.18158484, 0.24209644, 0.3155289, 0.76382697, 0.16301972, -0.1437822, 0.5974374, -0.40319166, 0.8555103, 0.43173182, 0.33494052, 0.8170414, -0.027123883, -0.035552304, 0.17036904, -0.034973294, -0.052836154, 1.4283096, 0.019494385, 0.13105609...</td>\n",
              "      <td>[[-0.047292054, 0.16946277, -0.14359778, -0.096518636, 0.0695647, 0.066515625, 0.057247654, 0.4592864, -0.19706547, 0.14917615, 0.29770166, 0.2808029, 0.23815095, 0.004138887, 0.14199351, 1.2531103, -0.20249727, -0.13582695, 0.69475114, 0.4762859...</td>\n",
              "    </tr>\n",
              "  </tbody>\n",
              "</table>\n",
              "</div>"
            ],
            "text/plain": [
              "                                                                                                                                                                                                                                                     question  \\\n",
              "0   Trying to get y friend to see a doctor but she wants to wait and see what happens. I'm worried sick and would like to know hat she might haveMy friend found a dime sized red lump a bit to the right of her clitoris in the shower this morning. its ...   \n",
              "1   Ease my worries pleaseMy husband is about to see a hematologist and googling around has me worried that he's got something serious, like aplastic anemia. I know we'll find out soon enough, but in the meantime, could you please suggest alternative...   \n",
              "2   Severe shoulder, neck and back pain after tetanus vaccinationA little less than a week ago I received my tetanus booster shot (the one you receive every decade, at least here in Australia).\\n\\nA few days later I began experiencing pain around my ...   \n",
              "3   Knee problemHere's the run down.  This past weekend my wife and I took part in a 3-day walk for breast cancer.  It was 60 miles, so clearly a lot of work on my knees.  Day 1 went fine, feet hurt, but to be expected.  Day two came and I was having...   \n",
              "4   Had a strange experience last night.Woke up in the middle of the night to take a leak. As I flushed the toilet I remember standing there feeling very light headed. I turned around and started to walk back to bed but never made it. Apparently I pa...   \n",
              "5                                Can anyone identify this?My 22 month old woke up with this.  We immediately took him to urgent care and they literally used the word, \"perplexed\" . We are waiting on an appointment on Monday. Any ideas would be helpful.    \n",
              "6   Bite, ingrown hair, infection?* [one](http://imgur.com/3901epB)\\n* [two](http://imgur.com/9w1QWlY)\\n* [three](http://imgur.com/TVDxF0H)\\n\\nAny idea what these are? The one on my cheek started off as a small scab (maybe a zit or something). I defi...   \n",
              "7   Busted my lip and need advice on how to heal it properly!I fell off my bike and busted my lip. I got four stitches on the inside, and just scratches on the outside. It is quite swollen and hard. I am hoping to get some advice on how make it heal ...   \n",
              "8   Just needed to know if this is \"normal\"- and ideally, why.The last 6-9 months, my (F,35) lymph nodes in my armpits painfully swell up about once a month, take about a week to go back to normal. When it first started happening, I went to an urgent...   \n",
              "9                                I've created a collection of amino acids and supplements that could potentially increase my release of HGH to 2000%-4000% what could be the consequences of executing this?I am under 18, so my plates have not yet closed.    \n",
              "10                                                                                                         Accidentally took 2 doses of tecta?I'm supposed to take 40mg of tecta daily, but I accidentally took it twice so I took 80mg in total, is that OK?   \n",
              "11  Brian hemorrhage mother in ICU: Want to know if these things are normal.My mother suffered from a Subarachnoid hemorrhage stroke (SAH) on 1/9/15. She had an aneurysm rupture behind her left eye. She has been in the ICU this whole time. Some info:...   \n",
              "12  Solutions or Treatments for Simulator Sickness\\nGeneral question:\\nMy fiance has some issues with Simulator sickness. We've tried some solutions such as siting further back from the screen or changing the field of view for games or movies, but to...   \n",
              "13  Should I be worried about my swollen lymph nodes?I'm a 17 y/o white F, 5 foot 1 and 118 pounds. For a little more than a week the lymph nodes in my left armpit have been swollen and painful both when touched and left on their own. In the past wee...   \n",
              "14                                     My partner is a designate female and I also am female She keeps having OrgasmsApparently the average woman doesn't have Orgasms and I'm wondering if this amount of orgasms she has is in excess. I also have Orgasms.   \n",
              "15  24f. Chest pain lasting hours, getting worse. What do I do?I am a 24 year-old female. I have been experiencing chest pain off and on for a few weeks. It's mostly in or around my ribs under my breasts. It feels like a pressure. It is not necessari...   \n",
              "16  Gynecomastia or Breast cancer?13\\nMale\\n177cm\\n60 kg\\nAmerican/Japanese\\nAt least 6 months\\nLeft nipple of breast\\nNo medical issues\\nNo medication\\n\\nI've had this bump that changes it's size and texture every now and again for at least 6 months...   \n",
              "17  Worried about heart *thumps*Age 31\\n\\nSex Male\\n\\nHeight 197cm\\n\\nWeight 180kg\\n\\nRace Caucasian\\n\\nDuration of complaint 2 days\\n\\nLocation (Geographic and on body) Heart\\n\\nAny existing relevant medical issues (if any) Type 2 diabetic\\n\\nCurren...   \n",
              "18  If two members of my extended family (aunt and uncle) were diagnosed with chronic leukemia, what is my chance of getting it?I was a smoker (recently quit), i'm 19 years old and my father does not have it. Although that same aunt also had vitiligo...   \n",
              "19  23M getting constant mouth UlcersHi,\\n\\nI am getting mouth ulcers all the time, the current one is right on the stringy bit underneath your bottom teeth, and after using special mouthwash last night and Ulcer gel, it is horrible today.\\n\\nBeen ge...   \n",
              "\n",
              "                                                                                                                                                                                                                                                       answer  \\\n",
              "0   This is most likely a Bartholin's Gland Cyst. On either side of the labia majora is a called a Bartholin's gland. Occasionally the ducts that empty the gland can become blocked causing the gland to develop a cyst. Sometimes they can go away on th...   \n",
              "1   Would be helpful with the exact values of the CBC. And B12, Folate and Ferritin values.\\n\\nAre liver and kidney function tests okay?\\n\\nWhat are his ethnic origins?,Is he diabetic. Does he take any other medication?,Does he take aspirin?\\nDid he ...   \n",
              "2   I seriously don't think your pain derives from the vaccination.\\n\\nIt looks like trapezoid contracture (is it the right word in english?).\\n\\nHeat and posture care should help you, elseways some muscular relaxant could be helpful.\\n\\nAnyways, at ...   \n",
              "3   It's possible that you caused some damage while playing sports and now with a heavy amount of activity caused aggravation of that injury. Its possible to cause a small tear in a meniscus and go years without any problems until a specific event ca...   \n",
              "4   Sounds like you had an episode of positional hypotension leading to syncope, or in other words, you stood up too fast causing a drop in blood pressure which made you pass out. If this was a one time thing you don't need to worry about it. Its pos...   \n",
              "5   It almost looks like prolonged exposure to something very hot. I'm not too sure what else it could be. Best of luck to you and your baby!,Yeah, my first thought was burning lesions, too.\\nThe other DD could be some pemphigoid lesion, but the skin...   \n",
              "6                                                          The ones in the beard look like Tinea, a fungal infection. \\nAnd I bet that the bigger one is also fungal, but made worse by scratching.\\n\\nYou should go to a GP for some anti fungal ointment...   \n",
              "7                                                                                                                                                                                                               Wash and wait.\\nTime is the only factor here.   \n",
              "8   This can be normal. This is happening every month, does it coincide with your medstrual cycle? Painful lymph nodes are nothing to worry about. This can happen with you have changes in hormones, when your body is trying to fight infections, etc. L...   \n",
              "9   You would develop Acromegaly, also known as Gigantism. It would have drastic effects on bone growth, fertility, muscle development, and several hormonal regulating systems in your body like sugar balance and insulin. You can check out the Wikiped...   \n",
              "10                                                                                                                                                                                                                                     yes, you will be fine.   \n",
              "11  &gt;4) Is it possible for TCD (transcranial doppler) and CAT scans to be wrong about vasospasms? \\n\\nSure, angiograms are still the gold standard. The evidence for the treatment of vasospasms in limited by the way, we do not no for sure if these ...   \n",
              "12                                           There are other non-antihistaminic treatments for motion sickness, I would guess I would try these (like scopolamine). I do would want to discuss the risk/benefit ratio for using drugs to enjoy certain games.   \n",
              "13                                                                                                                                                                                                               I think this warrants a trip to your doctor.   \n",
              "14                                                                                    &gt;Apparently the average woman doesn't have Orgasms \\n\\nThat isn't true.\\n\\n&gt;I'm wondering if this amount of orgasms she has is in excess\\n\\nExcess orgasms? What?   \n",
              "15  I would need much more information and i would actually want to see you to tell you anything other than go to the ER if you feel its serious. If the problem resolves itself defiantly call your primary care doc and talk to them. \\n  does the pain ...   \n",
              "16                                                                                                                     Breast cancer in a 13 year old male is tremendously rare.\\n\\nGynaecomastia can take quite a while longer than 6 months to resolve.\\n\\n   \n",
              "17  &gt;Danish names, hope it translates\\n\\nSure, metformin and losartan.\\n\\n&gt;The past couple of days about 1-2 times an hour my heart has made this \"thump\" in my chest like it is beating extra hard one time.\\n\\nThat sounds like a ventricular extr...   \n",
              "18  To date, we have no information on the existence of inheritable types of leukemia. So your chances are probably just as low as your next door neighbours chances. ,Do you know specifically what type of leukemia it is?,As /u murpahurp said, there i...   \n",
              "19  The gum might have sodium luyrate sulphate, (SLS), it's a chemical that can cause an allergic reaction. Totally agree with stopping the gum.  If it's still persistent, speak to your doctor about aphthous-like ulcers, which can be systemic manifes...   \n",
              "\n",
              "                                                                                                                                                                                                                                                question_bert  \\\n",
              "0   [[ 5.03139086e-02  1.75226659e-01 -1.97714433e-01 -7.32559934e-02\\n   3.20691824e-01 -1.78071290e-01  2.48940829e-02 -3.78650844e-01\\n  -3.47410381e-01  2.75857508e-01 -2.56084532e-01  2.22180486e-01\\n  -1.10391743e-01  1.29870668e-01  1.20820425...   \n",
              "1   [[-6.82685152e-02  4.29603830e-02 -3.32764566e-01 -6.10484481e-02\\n   1.12031415e-01 -2.02944130e-01 -9.14147869e-02 -2.58494318e-01\\n  -2.18344301e-01  2.87112653e-01 -6.67973831e-02 -9.51428413e-02\\n  -8.95148739e-02 -1.64768383e-01  2.71721900...   \n",
              "2   [[-9.59900767e-02  3.72468904e-02 -3.78887504e-01 -4.50596698e-02\\n   1.33349165e-01 -4.34329249e-02  4.04662602e-02 -2.44166061e-01\\n  -1.02068119e-01  4.49610293e-01 -5.45308404e-02 -8.46140832e-02\\n  -4.96546812e-02 -2.82016784e-01  3.25671524...   \n",
              "3   [[-1.29183223e-02 -2.05045454e-02 -5.12924075e-01 -1.66846707e-01\\n   7.68833160e-02 -2.10388333e-01 -1.76014677e-01 -1.63012460e-01\\n  -2.01517850e-01  4.29517597e-01 -5.23534641e-02  1.08745629e-02\\n  -2.42132619e-02  2.21630232e-03  2.81971633...   \n",
              "4   [[-1.07785672e-01  7.25684240e-02 -3.21571469e-01 -3.26673627e-01\\n   1.79342732e-01 -4.22933251e-02 -4.46543284e-02 -3.20031524e-01\\n  -3.15706164e-01  4.07414287e-01 -2.55068183e-01 -8.69708136e-02\\n  -1.83549866e-01  6.94538057e-02  2.84941673...   \n",
              "5   [[-1.80355459e-01  9.13417861e-02 -2.31477898e-02  1.68505371e-01\\n   3.64697009e-01 -2.84921029e-03  5.26331700e-02 -2.32272148e-01\\n  -2.76783496e-01  1.85831234e-01 -1.82725415e-01 -2.45477608e-03\\n  -5.56782305e-01  2.07249716e-01  4.03501727...   \n",
              "6   [[-4.58974428e-02  1.85957506e-01 -3.29710752e-01 -2.30540082e-01\\n  -3.92941460e-02 -8.59922394e-02 -2.67444197e-02 -2.28515729e-01\\n   2.24398915e-02  2.30619475e-01 -1.23537935e-01  2.24547207e-01\\n  -3.28298435e-02 -9.60415080e-02 -4.08210233...   \n",
              "7   [[ 4.99398075e-02  1.20460384e-01 -6.29447773e-02 -1.55243874e-01\\n  -1.44786581e-01 -2.17289880e-01  6.88850507e-02 -1.41801581e-01\\n  -9.79681034e-03  1.61795571e-01 -1.72716439e-01  2.97343414e-02\\n   1.00814886e-01  3.40392068e-02 -1.29933372...   \n",
              "8   [[ 1.09046437e-02  2.51035661e-01 -4.12880450e-01 -7.29131326e-02\\n  -3.01259682e-02  2.62525789e-02 -3.98364812e-02 -2.58315384e-01\\n  -2.89434969e-01  1.66334078e-01  6.32746443e-02 -2.08434202e-02\\n  -4.90285046e-02 -1.26866013e-01  2.41994068...   \n",
              "9   [[-8.31616744e-02  3.04023921e-01 -1.18793786e-01  1.61059380e-01\\n   1.25026569e-01 -2.26919770e-01  2.46555969e-01 -1.52935982e-01\\n  -2.75091082e-01  2.29911387e-01  6.95227832e-02  2.77909953e-02\\n  -2.28861675e-01 -8.43423828e-02  1.35876536...   \n",
              "10  [[-1.12157948e-01  4.43421781e-01 -2.27056161e-01  4.38472569e-01\\n   6.23993397e-01 -2.34182894e-01  3.34971458e-01 -1.92059025e-01\\n  -3.90465975e-01  2.35055134e-01  7.78263062e-02 -5.02863303e-02\\n  -4.39123243e-01  1.31034389e-01  4.63932425...   \n",
              "11  [[-2.29815200e-01 -2.73736473e-02 -3.96248132e-01 -1.15639813e-01\\n   4.00952473e-02 -1.44953832e-01 -1.33097336e-01 -2.18443498e-01\\n  -1.83913395e-01  4.09907192e-01 -5.54141030e-02  1.51335225e-01\\n  -3.08908634e-02 -7.50564784e-02  1.65862992...   \n",
              "12  [[-6.76830411e-02  2.11186498e-01 -3.51235420e-01  1.34276643e-01\\n  -3.78634445e-02 -1.99097946e-01 -4.19404991e-02 -7.24120997e-03\\n  -1.95001751e-01  7.00763911e-02 -1.31977037e-01  8.68828669e-02\\n  -2.35166326e-01  5.46145998e-02 -1.56805858...   \n",
              "13  [[-1.00367039e-01  1.71976656e-01 -3.27672809e-01 -1.25366449e-01\\n   2.28840232e-01 -1.99621424e-01  3.30793262e-02 -3.98666710e-01\\n  -2.62436420e-01  3.04824293e-01 -7.64185041e-02  1.63578838e-01\\n  -2.59301299e-03 -5.35064302e-02  3.54401350...   \n",
              "14  [[-2.51177996e-01  3.63571227e-01  3.47003564e-02 -2.08076998e-03\\n   3.20553362e-01  5.85481850e-03  3.72257084e-01 -5.54251730e-01\\n  -3.58152896e-01  1.61806028e-02  9.18404534e-02  1.79168910e-01\\n  -7.55692422e-02  2.79023618e-01  1.72599107...   \n",
              "15  [[-6.24945434e-03  1.23614438e-01 -3.61742765e-01 -2.03729138e-01\\n   2.37937406e-01 -1.22119091e-01 -8.30616280e-02 -3.95189911e-01\\n  -1.48478165e-01  3.74310017e-01 -2.12274566e-01  1.55362904e-01\\n  -3.24470364e-02 -6.42820299e-02  2.01565623...   \n",
              "16  [[-3.49072888e-02  2.72150069e-01 -3.78085911e-01  9.82727110e-02\\n   1.51978344e-01 -1.00297995e-01  1.58503816e-01 -3.41629684e-01\\n  -5.50584018e-01  2.49761224e-01 -1.55945316e-01 -2.77337115e-02\\n  -3.25412862e-02 -8.08728263e-02  2.57948697...   \n",
              "17  [[-7.61162415e-02 -2.23482531e-02 -2.50584573e-01 -8.25186539e-03\\n   8.61281753e-02 -2.20288441e-01  9.32557806e-02 -2.38561273e-01\\n  -2.53661007e-01  3.97102594e-01 -1.60614029e-01  8.40611532e-02\\n  -1.15015686e-01 -1.17804967e-01  2.35514179...   \n",
              "18  [[-1.76481977e-01  2.84115344e-01 -1.67520121e-01  1.47998661e-01\\n   2.00637728e-01 -6.31852522e-02  2.03767970e-01 -4.42649364e-01\\n  -6.00873232e-02 -9.57488790e-02  1.15900129e-01 -2.10186560e-02\\n  -2.63529301e-01 -3.08748037e-01  1.52012542...   \n",
              "19  [[-1.81584835e-01  2.42096439e-01 -2.76913613e-01  1.40295252e-01\\n   1.63019717e-01 -1.43782198e-01  1.12951100e-01 -4.03191656e-01\\n  -5.57388961e-01  3.51284325e-01  2.41640564e-02 -1.83883142e-02\\n  -2.71238834e-02 -3.55523042e-02  1.70369044...   \n",
              "\n",
              "                                                                                                                                                                                                                                                  answer_bert  \\\n",
              "0   [[-9.86990631e-02  2.09356025e-01 -4.21857655e-01 -3.36655468e-01\\n   4.87976819e-01 -7.02803209e-03 -3.16477306e-02 -1.65782422e-01\\n  -2.62371778e-01  2.40044087e-01 -2.24384233e-01  1.41379043e-01\\n   1.54396653e-01 -2.18005907e-02  1.46356851...   \n",
              "1   [[ 2.15814300e-02 -8.26028138e-02 -1.79856256e-01 -1.90481871e-01\\n   2.28367019e-02 -9.73006934e-02 -1.17688790e-01 -1.57697827e-01\\n  -1.08430490e-01  1.52954862e-01  1.85464919e-01 -1.62801355e-01\\n   2.00268812e-02 -2.12160777e-02  4.19895537...   \n",
              "2   [[-1.67309746e-01  6.44435063e-02  9.25731473e-03  1.30308941e-01\\n   1.98665693e-01  1.11179024e-01  3.86667326e-02 -2.81090587e-01\\n  -1.66967526e-01  2.28748009e-01  6.09516762e-02  2.41061822e-02\\n   2.80033629e-02 -1.44916847e-01  2.37973034...   \n",
              "3   [[-6.90914094e-02 -1.75325274e-01 -2.17794701e-01 -3.16970319e-01\\n   4.53783050e-02  2.69050837e-01 -8.84563774e-02 -5.35140410e-02\\n  -1.40716955e-01  2.62832701e-01  5.61185367e-02 -7.53825307e-02\\n  -3.30312178e-03 -1.45833969e-01  7.09648505...   \n",
              "4   [[ 1.17936537e-01  3.22081089e-01 -2.68315077e-01 -3.22643697e-01\\n   2.45345443e-01  1.22372217e-01 -6.57593310e-02 -3.15712541e-01\\n  -4.09232318e-01  3.51304054e-01 -1.17886476e-01 -1.15702309e-01\\n  -1.23623818e-01  5.74846864e-02 -5.51498830...   \n",
              "5   [[-8.75879154e-02  2.78869659e-01  7.62948021e-03 -1.34483024e-01\\n   2.21360382e-02  1.17703408e-01  1.85167156e-02 -2.49677420e-01\\n  -2.66380191e-01  1.92860708e-01 -2.41361745e-02  1.67692788e-02\\n  -2.19728127e-01 -3.16680670e-02  6.96710646...   \n",
              "6   [[-8.41102079e-02  1.84079811e-01 -8.89919475e-02 -2.76612118e-02\\n   2.09251344e-01  2.61974871e-01  9.31475013e-02 -3.65237713e-01\\n  -3.54500890e-01  2.28741035e-01 -8.78387317e-02  2.49303564e-01\\n  -2.21121296e-01  4.75698560e-02  1.38536990...   \n",
              "7   [[ 3.61181676e-01  9.27573293e-02 -2.03941107e-01  3.56207043e-01\\n   4.41465884e-01 -2.86622703e-01  4.93434727e-01 -2.53519654e-01\\n  -4.14035097e-02 -1.14065088e-01 -5.41325927e-01  4.32440013e-01\\n   1.31187424e-01  4.03006256e-01 -7.08923340...   \n",
              "8   [[-5.89954145e-02  9.62038636e-02 -1.60867006e-01 -2.52489001e-01\\n  -1.09475821e-01  6.57585487e-02 -3.30365486e-02 -3.27971756e-01\\n  -2.58334517e-01  1.66886181e-01  1.31579293e-02  2.67492924e-02\\n   1.93602532e-01  1.12057813e-01  2.15599194...   \n",
              "9   [[-1.76602155e-01  6.17301278e-02 -6.11533299e-02 -1.70265079e-01\\n  -1.04844943e-01 -1.67983010e-01  1.36407509e-01 -2.09834725e-01\\n   8.97120684e-02  6.27892911e-02 -2.77223855e-01  1.51995748e-01\\n   3.47727656e-01 -1.78699754e-02 -4.71802324...   \n",
              "10  [[ 6.88412189e-02  2.50665486e-01  1.33473709e-01  2.63651192e-01\\n  -2.29095384e-01  2.68963486e-01  3.97941440e-01 -3.45116228e-01\\n  -2.56032646e-01 -1.50789842e-01  6.33369684e-02 -1.57825381e-01\\n   1.31796360e-01  1.03793032e-01 -1.89787194...   \n",
              "11  [[ 1.06997713e-01  1.39075860e-01 -1.63705066e-01  3.04865420e-01\\n   3.85065556e-01 -7.77797028e-02 -5.99039756e-02 -3.22348833e-01\\n  -7.88318068e-02  4.58603688e-02 -2.27341056e-01 -2.92531729e-01\\n  -1.09925605e-01  1.62464947e-01 -1.13994867...   \n",
              "12  [[-1.32732004e-01  6.73507228e-02 -1.56957269e-01  8.61029401e-02\\n  -8.40305239e-02 -2.15575442e-01  1.22828379e-01 -8.41380954e-02\\n  -5.01216240e-02 -8.34617987e-02 -2.05751881e-01  4.20058295e-02\\n  -1.55402228e-01  2.09729657e-01 -9.05604661...   \n",
              "13  [[ 1.53559282e-01  1.29343063e-01  1.96472570e-01  5.89777417e-02\\n  -3.78266871e-02  4.09878120e-02  4.34025019e-01 -4.41730499e-01\\n  -1.51526034e-01 -1.98788866e-01  8.50769654e-02 -1.79388821e-01\\n   2.52134532e-01 -1.64774403e-01  2.96966136...   \n",
              "14  [[-2.91481555e-01  4.76583719e-01 -4.21611182e-02  2.23754078e-01\\n   1.99215516e-01 -9.85787287e-02  4.28873539e-01 -5.40630281e-01\\n  -2.82934368e-01  5.40661216e-02  1.92386284e-02  2.64240295e-01\\n   1.13377452e-01  3.98269072e-02  1.86027139...   \n",
              "15  [[ 9.48783159e-02 -1.29473612e-01 -4.10793312e-02 -2.53820181e-01\\n   2.60319352e-01  1.28168270e-01 -1.11271478e-01 -5.47138713e-02\\n  -2.53896177e-01  3.35424989e-01  5.38754882e-03 -1.34149557e-02\\n   4.28323913e-03 -1.43202856e-01  2.61246741...   \n",
              "16  [[-1.90779299e-01  1.72353283e-01 -1.10838704e-01  2.59033829e-01\\n   4.67246532e-01 -1.08562537e-01 -8.70064553e-03 -1.83964610e-01\\n  -1.20578162e-01  1.83340788e-01 -2.65375882e-01  2.15853944e-01\\n   2.99135804e-01  2.08692431e-01  1.04468204...   \n",
              "17  [[-9.71726552e-02  7.27577507e-02 -2.53779143e-01 -1.59242183e-01\\n   2.81454384e-01 -6.17131293e-02  2.29519438e-02 -1.79074004e-01\\n  -1.26287997e-01  2.36242399e-01 -1.87451720e-01  4.43626903e-02\\n   7.29264095e-02 -1.07286997e-01  1.76546350...   \n",
              "18  [[-1.59571663e-01  1.56269968e-01 -2.98799515e-01 -2.09489346e-01\\n   2.34919831e-01  3.27772908e-02  1.16240576e-01 -1.56799674e-01\\n  -9.09149460e-03 -3.49322110e-02 -8.62018615e-02  5.06505072e-02\\n  -1.09480605e-01  7.82237276e-02 -1.76918000...   \n",
              "19  [[-4.72920537e-02  1.69462770e-01 -1.43597782e-01 -9.65186357e-02\\n   6.95647001e-02  6.65156245e-02 -1.41030952e-01 -1.60091773e-01\\n  -1.97065473e-01  1.49176151e-01  2.97701657e-01  1.56476691e-01\\n  -6.36801049e-02 -1.30709529e-01  1.41993508...   \n",
              "\n",
              "                                                                                                                                                                                                                                                Q_FFNN_embeds  \\\n",
              "0   [[0.05031391, 0.17522666, 0.71465725, 0.5769979, 0.32069182, -0.17807129, 1.2392216, -0.37865084, 0.1199767, 0.2758575, -0.002445519, 0.3054453, -0.11039174, 0.56973076, 0.120820425, -0.107291855, -0.17624098, 0.23657487, -0.23213816, 0.33558795,...   \n",
              "1   [[-0.068268515, 0.042960383, 0.17118096, 0.26986143, 0.112031415, -0.20294413, 0.7771517, -0.25849432, 0.59284496, 0.6635877, 0.3940065, -0.09514284, -0.089514874, 0.33704883, 0.2717219, -0.18564875, 0.1500851, 1.5225036, -0.21757159, 0.2978152, ...   \n",
              "2   [[-0.09599008, 0.03724689, 0.10206425, 0.4240935, 0.13334917, -0.043432925, 1.1233978, -0.24416606, 0.57163686, 0.4496103, -0.05453084, -0.060560953, -0.04965468, -0.28201678, 0.32567152, -0.12495111, -0.051384494, 1.0094256, -0.15498431, 0.43008...   \n",
              "3   [[-0.012918322, -0.020504545, 0.4435106, 0.19794388, 0.076883316, -0.21038833, 0.5508412, -0.16301246, 0.53401446, 0.48718905, 0.5478626, 0.13116859, -0.024213262, 0.0022163023, 0.28197163, -0.17161314, 0.30555886, 0.1917058, -0.40395558, 0.17525...   \n",
              "4   [[-0.10778567, 0.072568424, 0.6073649, -0.20827225, 0.17934273, -0.042293325, 0.39158764, -0.32003152, 0.3331981, 0.48051676, -0.10623282, 0.5591209, -0.18354987, 0.28779644, 0.28494167, 0.008892038, 0.57379186, 0.88093156, -0.15870328, 0.1819411...   \n",
              "5   [[-0.18035546, 0.091341786, 0.14185199, 0.26876837, 0.364697, -0.0028492103, 0.05263317, -0.23227215, 0.63868487, 0.459853, 0.3550713, 0.11367951, -0.5567823, 0.37561405, 0.040350173, -0.15050356, -0.09284662, -0.20346472, 0.07705624, 0.35358286,...   \n",
              "6   [[-0.045897443, 0.1859575, 0.79868317, 0.4142545, -0.039294146, -0.08599224, 0.92267793, -0.22851573, 0.56371015, 0.31517312, 0.77103704, 0.24593458, -0.032829843, 0.49358177, -0.040821023, 0.039925233, -0.23192735, 0.19133624, -0.45759693, 0.062...   \n",
              "7   [[0.049939808, 0.12046038, 0.61080974, 0.10166994, -0.14478658, -0.21728988, 1.2853746, -0.14180158, -0.00979681, 0.16179557, 0.2864955, 0.87758493, 0.10081489, 0.25402442, -0.12993337, 0.1418176, -0.2160801, -0.046122134, -0.31051943, 0.19090335...   \n",
              "8   [[0.010904644, 0.25103566, 0.13396052, 0.4604362, -0.030125968, 0.026252579, 0.6074764, -0.25831538, 0.34907365, 0.49096107, 0.46270916, 0.30601597, -0.049028505, 0.11198901, 0.24199407, -0.12763695, 0.0048868647, 0.40711734, -0.3820984, 0.378389...   \n",
              "9   [[-0.083161674, 0.30402392, 0.9112342, 0.16105938, 0.1272867, -0.22691977, 0.8712962, -0.15293598, 0.2285243, 0.69513017, 0.06952278, 0.027790995, -0.22886167, -0.08434238, 0.13587654, -0.21821095, -0.028593391, -0.040001836, 0.06398056, 0.233339...   \n",
              "10  [[-0.11215795, 0.44342178, -0.22705616, 0.9130324, 0.6239934, -0.2341829, 0.99952507, -0.19205903, -0.39046597, 0.23505513, 0.89798194, -0.05028633, -0.43912324, 0.13103439, 0.46393242, -0.18600073, 0.46653593, 0.5945296, -0.09542866, 1.002146, 0...   \n",
              "11  [[-0.2298152, -0.027373647, 0.2343978, 0.118794404, 0.040095247, -0.14495383, 0.55689496, -0.2184435, 0.4118657, 0.84105134, -0.022418566, 0.15133522, -0.030890863, 0.54792094, 0.16586299, 0.00252006, 0.4403717, 0.46651894, -0.19945136, 0.2714683...   \n",
              "12  [[-0.06768304, 0.2111865, 1.33728, 0.4093728, -0.037863445, -0.19909795, 0.59675986, -0.00724121, 1.2763453, 0.8271443, -0.050741434, 0.08688287, -0.23516633, 1.263954, -0.15680586, -0.090711355, 0.40230146, -0.109419316, -0.11487891, 0.41448542,...   \n",
              "13  [[-0.10036704, 0.17197666, 0.6682855, -0.06802086, 0.22884023, -0.19962142, 0.55211335, -0.3986667, 0.6215303, 0.5883613, 0.56345475, 0.7833128, -0.002593013, 0.41028988, 0.35440135, -0.09089787, -0.038822114, 0.9048873, -0.11726918, 0.41297364, ...   \n",
              "14  [[-0.251178, 0.36357123, 0.19599599, 0.4916827, 0.32055336, 0.0058548185, 0.58947575, -0.55425173, -0.35607582, 1.0378833, 0.64087886, 1.6529472, -0.07556924, 0.61150223, 0.1725991, -0.0116100665, 0.20288852, 0.7131314, -0.12291423, 0.37912995, -...   \n",
              "15  [[-0.0062494543, 0.12361444, 0.59349835, 0.025204405, 0.2379374, -0.12211909, 0.5145799, -0.3951899, 1.1732261, 0.699885, -0.21227457, 0.46315265, -0.032447036, 0.26972327, 0.20156562, -0.05767897, -0.02102714, 0.47356787, -0.21486072, 0.21103245...   \n",
              "16  [[-0.03490729, 0.27215007, 0.51699543, 0.5875977, 0.15197834, -0.100297995, 0.3306139, -0.34162968, 0.6238052, 0.24976122, 0.15855102, -0.027733712, -0.032541286, 0.55993277, 0.2579487, -0.03114066, -0.19984771, 1.0968158, 0.027874587, 0.24369775...   \n",
              "17  [[-0.07611624, -0.022348253, 0.751212, 0.09780994, 0.086128175, -0.22028844, 0.83830035, -0.23856127, 0.6291239, 0.3971026, -0.0152027905, 0.36427912, -0.115015686, 0.40980598, 0.23551418, -0.07058594, -0.059574872, 0.4545892, -0.1583698, 0.31147...   \n",
              "18  [[-0.17648198, 0.28411534, 0.38130414, 0.3100694, 0.20063773, -0.03262607, 0.9389497, -0.44264936, 1.9756128, -0.09574888, 1.3066144, -0.021018656, -0.2635293, -0.27166194, 0.15201254, 0.0023924613, 1.0857308, 0.9102626, 0.2169805, 0.48707527, -0...   \n",
              "19  [[-0.18158484, 0.24209644, 0.3155289, 0.76382697, 0.16301972, -0.1437822, 0.5974374, -0.40319166, 0.8555103, 0.43173182, 0.33494052, 0.8170414, -0.027123883, -0.035552304, 0.17036904, -0.034973294, -0.052836154, 1.4283096, 0.019494385, 0.13105609...   \n",
              "\n",
              "                                                                                                                                                                                                                                                A_FFNN_embeds  \n",
              "0   [[-0.09869906, 0.20935602, -0.42185766, -0.33665547, 0.48797682, -0.007028032, 0.07065214, -0.16578242, -0.26237178, 0.24004409, -0.22438423, 0.18115889, 0.4567215, -0.02180059, 0.14635685, 0.74769473, -0.026884364, -0.2658844, 0.35665464, 0.3084...  \n",
              "1   [[0.02158143, -0.082602814, -0.17985626, -0.19048187, 0.022836702, -0.09730069, 0.3418817, -0.15769783, -0.10843049, 0.15295486, 0.18546492, 0.09176144, 0.64303726, 0.27884188, 0.041989554, 0.09366697, 0.1290735, -0.11779204, 0.46386075, 0.239391...  \n",
              "2   [[-0.16730975, 0.06444351, 0.009257315, 0.13030894, 0.1986657, 0.111179024, 0.050693758, -0.2810906, -0.16696753, 0.22874801, 0.060951676, 0.024106182, 0.10953758, -0.14491685, 0.23797303, 0.14848688, -0.06242373, -0.3347124, 0.35131043, 0.427723...  \n",
              "3   [[-0.06909141, -0.11909217, -0.2177947, -0.31697032, 0.045378305, 0.26905084, 0.2377099, -0.05351404, -0.14071696, 0.2628327, 0.056118537, -0.07538253, 0.8720115, -0.14583397, 0.07096485, 0.5082699, 0.21771231, -0.33978415, 0.3260417, 0.27947804,...  \n",
              "4   [[0.11793654, 0.3220811, -0.26831508, -0.3226437, 0.24534544, 0.12237222, -0.06575933, -0.31571254, -0.40923232, 0.35130405, -0.117886476, -0.11570231, 0.7159771, 0.14493895, -0.055149883, 1.7910986, 0.090899386, -0.27257594, -0.0984668, 0.167966...  \n",
              "5   [[-0.087587915, 0.27886966, 0.00762948, -0.13448302, 0.022136038, 0.11770341, 0.018516716, -0.24967742, -0.2663802, 0.43704742, -0.024136174, 0.016769279, -0.21972813, 0.099903345, 0.069671065, 0.35788065, 0.19415134, -0.3672943, 0.0820634, 0.321...  \n",
              "6   [[-0.08411021, 0.18407981, -0.08899195, -0.027661212, 0.20925134, 0.26197487, 0.0931475, -0.3652377, -0.3545009, 0.22874103, -0.05313527, 0.24930356, -0.21285923, 0.047569856, 0.13853699, 1.0090455, -0.08114073, -0.19877541, -0.15805234, 0.389106...  \n",
              "7   [[0.36118168, 0.53679043, 0.09158689, 0.35620704, 0.8140732, -0.2866227, 0.49343473, -0.25351965, -0.04140351, -0.11406509, -0.5413259, 0.550707, 0.13118742, 0.40300626, -0.070892334, -0.1997576, 0.60152066, 0.44648597, -0.07755573, 0.65332866, 0...  \n",
              "8   [[-0.058995415, 0.09620386, -0.160867, -0.252489, -0.10947582, 0.06575855, 0.3831236, -0.32797176, -0.25833452, 0.16688618, 0.013157929, 0.23609565, 0.80914056, 0.25079644, 0.2155992, 1.3976666, 0.07401086, -0.22676554, -0.05611816, 0.37811735, -...  \n",
              "9   [[-0.17660215, 1.2277203, -0.06115333, -0.17026508, 1.0580376, -0.16798301, 0.24272121, -0.20983472, 0.08971207, 0.6569524, -0.27722386, 0.4281262, 0.48739827, 0.2324163, -0.47180232, -0.18792889, -0.19671606, -0.57597274, 0.12601036, 0.44215077,...  \n",
              "10  [[0.06884122, 0.3991459, 0.13347371, 1.2714124, 0.4602924, 0.2689635, 0.4293988, -0.34511623, -0.07977429, -0.15078984, 0.1119453, -0.15782538, 0.13179636, 0.10379303, -0.1897872, 0.073030375, -0.048009794, -0.22115533, -0.16689084, 1.2068557, -0...  \n",
              "11  [[0.10699771, 0.13907586, -0.16370507, 0.30486542, 0.4369713, -0.0777797, -0.0005571209, -0.32234883, -0.07883181, 0.04586037, -0.22734106, 0.11739552, 1.2917163, 0.50037754, -0.11399487, -0.027811646, 0.33034086, -0.1898757, -0.18361315, 0.08811...  \n",
              "12  [[-0.132732, 0.79169184, -0.15695727, 0.08610294, -0.084030524, -0.21557544, 0.43121457, -0.05919546, -0.050121624, 0.116889946, 0.16201825, 0.14344037, 0.22812246, 0.20972966, -0.009056047, -0.06952244, 0.17648898, 0.33555833, -0.22924715, 0.138...  \n",
              "13  [[0.15355928, 0.9022887, 0.19647257, 0.05897774, -0.037826687, 0.040987812, 0.65439725, -0.4417305, -0.15152603, -0.13688846, 0.085076965, 0.09020758, 1.3557999, -0.1647744, 0.29696614, -0.06793762, -0.16783336, 0.042502217, -0.113421805, 1.49819...  \n",
              "14  [[-0.29148155, 0.47658372, -0.04216112, 0.22375408, 0.19921552, -0.09857873, 0.42887354, -0.5406303, -0.28293437, 0.88321656, 0.019238628, 0.2642403, 0.8570628, 0.07455567, 0.18602714, 1.9101144, 0.122920565, -0.040849674, 0.18245947, 0.47146246,...  \n",
              "15  [[0.094878316, -0.12947361, -0.04107933, -0.25382018, 0.26031935, 0.12816827, 0.06646284, -0.05471387, -0.25389618, 0.335425, 0.005387549, -0.013414956, 0.06603424, -0.14320286, 0.26124674, 0.78168005, -0.0045633763, -0.23666911, 0.5200337, 0.251...  \n",
              "16  [[-0.1907793, 0.8906218, -0.110838704, 0.80821145, 0.46724653, -0.10856254, 0.44675112, -0.18396461, 0.32830828, 0.18334079, -0.26537588, 0.3562675, 1.3322723, 0.32925254, 0.104468204, -0.12629494, -0.07290969, -0.2992357, 0.09363668, 0.6341158, ...  \n",
              "17  [[-0.097172655, 0.07275775, -0.25377914, -0.15924218, 0.28145438, -0.06171313, 0.34107372, -0.179074, -0.126288, 0.2362424, -0.18745172, 0.24850127, 0.573665, -0.0249039, 0.17654635, 0.60749644, -0.1722704, -0.3090028, 0.047246233, 0.31476793, 0....  \n",
              "18  [[-0.15957166, 0.40267903, -0.2987995, -0.20948935, 0.23491983, 0.03277729, 0.31468588, -0.15679967, -0.009091495, -0.03493221, -0.08620186, 0.060476154, -0.066437975, 0.07822373, -0.176918, -0.2508848, 0.036230676, -0.24474354, 0.32010782, 0.410...  \n",
              "19  [[-0.047292054, 0.16946277, -0.14359778, -0.096518636, 0.0695647, 0.066515625, 0.057247654, 0.4592864, -0.19706547, 0.14917615, 0.29770166, 0.2808029, 0.23815095, 0.004138887, 0.14199351, 1.2531103, -0.20249727, -0.13582695, 0.69475114, 0.4762859...  "
            ]
          },
          "metadata": {
            "tags": []
          },
          "execution_count": 27
        }
      ]
    },
    {
      "metadata": {
        "id": "Mul-T5P330os",
        "colab_type": "code",
        "colab": {}
      },
      "cell_type": "code",
      "source": [
        "del askDocspd['question_bert']\n",
        "del askDocspd['answer_bert']"
      ],
      "execution_count": 0,
      "outputs": []
    },
    {
      "metadata": {
        "id": "svo_I6oM8_1N",
        "colab_type": "code",
        "outputId": "13a846ac-1c46-4827-c22d-50661fdb4fe1",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 2655
        }
      },
      "cell_type": "code",
      "source": [
        "askDocspd.head(20)"
      ],
      "execution_count": 0,
      "outputs": [
        {
          "output_type": "execute_result",
          "data": {
            "text/html": [
              "<div>\n",
              "<style scoped>\n",
              "    .dataframe tbody tr th:only-of-type {\n",
              "        vertical-align: middle;\n",
              "    }\n",
              "\n",
              "    .dataframe tbody tr th {\n",
              "        vertical-align: top;\n",
              "    }\n",
              "\n",
              "    .dataframe thead th {\n",
              "        text-align: right;\n",
              "    }\n",
              "</style>\n",
              "<table border=\"1\" class=\"dataframe\">\n",
              "  <thead>\n",
              "    <tr style=\"text-align: right;\">\n",
              "      <th></th>\n",
              "      <th>question</th>\n",
              "      <th>answer</th>\n",
              "      <th>Q_FFNN_embeds</th>\n",
              "      <th>A_FFNN_embeds</th>\n",
              "    </tr>\n",
              "  </thead>\n",
              "  <tbody>\n",
              "    <tr>\n",
              "      <th>0</th>\n",
              "      <td>Trying to get y friend to see a doctor but she wants to wait and see what happens. I'm worried sick and would like to know hat she might haveMy friend found a dime sized red lump a bit to the right of her clitoris in the shower this morning. its ...</td>\n",
              "      <td>This is most likely a Bartholin's Gland Cyst. On either side of the labia majora is a called a Bartholin's gland. Occasionally the ducts that empty the gland can become blocked causing the gland to develop a cyst. Sometimes they can go away on th...</td>\n",
              "      <td>[[0.05031391, 0.17522666, 0.71465725, 0.5769979, 0.32069182, -0.17807129, 1.2392216, -0.37865084, 0.1199767, 0.2758575, -0.002445519, 0.3054453, -0.11039174, 0.56973076, 0.120820425, -0.107291855, -0.17624098, 0.23657487, -0.23213816, 0.33558795,...</td>\n",
              "      <td>[[-0.09869906, 0.20935602, -0.42185766, -0.33665547, 0.48797682, -0.007028032, 0.07065214, -0.16578242, -0.26237178, 0.24004409, -0.22438423, 0.18115889, 0.4567215, -0.02180059, 0.14635685, 0.74769473, -0.026884364, -0.2658844, 0.35665464, 0.3084...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>1</th>\n",
              "      <td>Ease my worries pleaseMy husband is about to see a hematologist and googling around has me worried that he's got something serious, like aplastic anemia. I know we'll find out soon enough, but in the meantime, could you please suggest alternative...</td>\n",
              "      <td>Would be helpful with the exact values of the CBC. And B12, Folate and Ferritin values.\\n\\nAre liver and kidney function tests okay?\\n\\nWhat are his ethnic origins?,Is he diabetic. Does he take any other medication?,Does he take aspirin?\\nDid he ...</td>\n",
              "      <td>[[-0.068268515, 0.042960383, 0.17118096, 0.26986143, 0.112031415, -0.20294413, 0.7771517, -0.25849432, 0.59284496, 0.6635877, 0.3940065, -0.09514284, -0.089514874, 0.33704883, 0.2717219, -0.18564875, 0.1500851, 1.5225036, -0.21757159, 0.2978152, ...</td>\n",
              "      <td>[[0.02158143, -0.082602814, -0.17985626, -0.19048187, 0.022836702, -0.09730069, 0.3418817, -0.15769783, -0.10843049, 0.15295486, 0.18546492, 0.09176144, 0.64303726, 0.27884188, 0.041989554, 0.09366697, 0.1290735, -0.11779204, 0.46386075, 0.239391...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>2</th>\n",
              "      <td>Severe shoulder, neck and back pain after tetanus vaccinationA little less than a week ago I received my tetanus booster shot (the one you receive every decade, at least here in Australia).\\n\\nA few days later I began experiencing pain around my ...</td>\n",
              "      <td>I seriously don't think your pain derives from the vaccination.\\n\\nIt looks like trapezoid contracture (is it the right word in english?).\\n\\nHeat and posture care should help you, elseways some muscular relaxant could be helpful.\\n\\nAnyways, at ...</td>\n",
              "      <td>[[-0.09599008, 0.03724689, 0.10206425, 0.4240935, 0.13334917, -0.043432925, 1.1233978, -0.24416606, 0.57163686, 0.4496103, -0.05453084, -0.060560953, -0.04965468, -0.28201678, 0.32567152, -0.12495111, -0.051384494, 1.0094256, -0.15498431, 0.43008...</td>\n",
              "      <td>[[-0.16730975, 0.06444351, 0.009257315, 0.13030894, 0.1986657, 0.111179024, 0.050693758, -0.2810906, -0.16696753, 0.22874801, 0.060951676, 0.024106182, 0.10953758, -0.14491685, 0.23797303, 0.14848688, -0.06242373, -0.3347124, 0.35131043, 0.427723...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>3</th>\n",
              "      <td>Knee problemHere's the run down.  This past weekend my wife and I took part in a 3-day walk for breast cancer.  It was 60 miles, so clearly a lot of work on my knees.  Day 1 went fine, feet hurt, but to be expected.  Day two came and I was having...</td>\n",
              "      <td>It's possible that you caused some damage while playing sports and now with a heavy amount of activity caused aggravation of that injury. Its possible to cause a small tear in a meniscus and go years without any problems until a specific event ca...</td>\n",
              "      <td>[[-0.012918322, -0.020504545, 0.4435106, 0.19794388, 0.076883316, -0.21038833, 0.5508412, -0.16301246, 0.53401446, 0.48718905, 0.5478626, 0.13116859, -0.024213262, 0.0022163023, 0.28197163, -0.17161314, 0.30555886, 0.1917058, -0.40395558, 0.17525...</td>\n",
              "      <td>[[-0.06909141, -0.11909217, -0.2177947, -0.31697032, 0.045378305, 0.26905084, 0.2377099, -0.05351404, -0.14071696, 0.2628327, 0.056118537, -0.07538253, 0.8720115, -0.14583397, 0.07096485, 0.5082699, 0.21771231, -0.33978415, 0.3260417, 0.27947804,...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>4</th>\n",
              "      <td>Had a strange experience last night.Woke up in the middle of the night to take a leak. As I flushed the toilet I remember standing there feeling very light headed. I turned around and started to walk back to bed but never made it. Apparently I pa...</td>\n",
              "      <td>Sounds like you had an episode of positional hypotension leading to syncope, or in other words, you stood up too fast causing a drop in blood pressure which made you pass out. If this was a one time thing you don't need to worry about it. Its pos...</td>\n",
              "      <td>[[-0.10778567, 0.072568424, 0.6073649, -0.20827225, 0.17934273, -0.042293325, 0.39158764, -0.32003152, 0.3331981, 0.48051676, -0.10623282, 0.5591209, -0.18354987, 0.28779644, 0.28494167, 0.008892038, 0.57379186, 0.88093156, -0.15870328, 0.1819411...</td>\n",
              "      <td>[[0.11793654, 0.3220811, -0.26831508, -0.3226437, 0.24534544, 0.12237222, -0.06575933, -0.31571254, -0.40923232, 0.35130405, -0.117886476, -0.11570231, 0.7159771, 0.14493895, -0.055149883, 1.7910986, 0.090899386, -0.27257594, -0.0984668, 0.167966...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>5</th>\n",
              "      <td>Can anyone identify this?My 22 month old woke up with this.  We immediately took him to urgent care and they literally used the word, \"perplexed\" . We are waiting on an appointment on Monday. Any ideas would be helpful.</td>\n",
              "      <td>It almost looks like prolonged exposure to something very hot. I'm not too sure what else it could be. Best of luck to you and your baby!,Yeah, my first thought was burning lesions, too.\\nThe other DD could be some pemphigoid lesion, but the skin...</td>\n",
              "      <td>[[-0.18035546, 0.091341786, 0.14185199, 0.26876837, 0.364697, -0.0028492103, 0.05263317, -0.23227215, 0.63868487, 0.459853, 0.3550713, 0.11367951, -0.5567823, 0.37561405, 0.040350173, -0.15050356, -0.09284662, -0.20346472, 0.07705624, 0.35358286,...</td>\n",
              "      <td>[[-0.087587915, 0.27886966, 0.00762948, -0.13448302, 0.022136038, 0.11770341, 0.018516716, -0.24967742, -0.2663802, 0.43704742, -0.024136174, 0.016769279, -0.21972813, 0.099903345, 0.069671065, 0.35788065, 0.19415134, -0.3672943, 0.0820634, 0.321...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>6</th>\n",
              "      <td>Bite, ingrown hair, infection?* [one](http://imgur.com/3901epB)\\n* [two](http://imgur.com/9w1QWlY)\\n* [three](http://imgur.com/TVDxF0H)\\n\\nAny idea what these are? The one on my cheek started off as a small scab (maybe a zit or something). I defi...</td>\n",
              "      <td>The ones in the beard look like Tinea, a fungal infection. \\nAnd I bet that the bigger one is also fungal, but made worse by scratching.\\n\\nYou should go to a GP for some anti fungal ointment...</td>\n",
              "      <td>[[-0.045897443, 0.1859575, 0.79868317, 0.4142545, -0.039294146, -0.08599224, 0.92267793, -0.22851573, 0.56371015, 0.31517312, 0.77103704, 0.24593458, -0.032829843, 0.49358177, -0.040821023, 0.039925233, -0.23192735, 0.19133624, -0.45759693, 0.062...</td>\n",
              "      <td>[[-0.08411021, 0.18407981, -0.08899195, -0.027661212, 0.20925134, 0.26197487, 0.0931475, -0.3652377, -0.3545009, 0.22874103, -0.05313527, 0.24930356, -0.21285923, 0.047569856, 0.13853699, 1.0090455, -0.08114073, -0.19877541, -0.15805234, 0.389106...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>7</th>\n",
              "      <td>Busted my lip and need advice on how to heal it properly!I fell off my bike and busted my lip. I got four stitches on the inside, and just scratches on the outside. It is quite swollen and hard. I am hoping to get some advice on how make it heal ...</td>\n",
              "      <td>Wash and wait.\\nTime is the only factor here.</td>\n",
              "      <td>[[0.049939808, 0.12046038, 0.61080974, 0.10166994, -0.14478658, -0.21728988, 1.2853746, -0.14180158, -0.00979681, 0.16179557, 0.2864955, 0.87758493, 0.10081489, 0.25402442, -0.12993337, 0.1418176, -0.2160801, -0.046122134, -0.31051943, 0.19090335...</td>\n",
              "      <td>[[0.36118168, 0.53679043, 0.09158689, 0.35620704, 0.8140732, -0.2866227, 0.49343473, -0.25351965, -0.04140351, -0.11406509, -0.5413259, 0.550707, 0.13118742, 0.40300626, -0.070892334, -0.1997576, 0.60152066, 0.44648597, -0.07755573, 0.65332866, 0...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>8</th>\n",
              "      <td>Just needed to know if this is \"normal\"- and ideally, why.The last 6-9 months, my (F,35) lymph nodes in my armpits painfully swell up about once a month, take about a week to go back to normal. When it first started happening, I went to an urgent...</td>\n",
              "      <td>This can be normal. This is happening every month, does it coincide with your medstrual cycle? Painful lymph nodes are nothing to worry about. This can happen with you have changes in hormones, when your body is trying to fight infections, etc. L...</td>\n",
              "      <td>[[0.010904644, 0.25103566, 0.13396052, 0.4604362, -0.030125968, 0.026252579, 0.6074764, -0.25831538, 0.34907365, 0.49096107, 0.46270916, 0.30601597, -0.049028505, 0.11198901, 0.24199407, -0.12763695, 0.0048868647, 0.40711734, -0.3820984, 0.378389...</td>\n",
              "      <td>[[-0.058995415, 0.09620386, -0.160867, -0.252489, -0.10947582, 0.06575855, 0.3831236, -0.32797176, -0.25833452, 0.16688618, 0.013157929, 0.23609565, 0.80914056, 0.25079644, 0.2155992, 1.3976666, 0.07401086, -0.22676554, -0.05611816, 0.37811735, -...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>9</th>\n",
              "      <td>I've created a collection of amino acids and supplements that could potentially increase my release of HGH to 2000%-4000% what could be the consequences of executing this?I am under 18, so my plates have not yet closed.</td>\n",
              "      <td>You would develop Acromegaly, also known as Gigantism. It would have drastic effects on bone growth, fertility, muscle development, and several hormonal regulating systems in your body like sugar balance and insulin. You can check out the Wikiped...</td>\n",
              "      <td>[[-0.083161674, 0.30402392, 0.9112342, 0.16105938, 0.1272867, -0.22691977, 0.8712962, -0.15293598, 0.2285243, 0.69513017, 0.06952278, 0.027790995, -0.22886167, -0.08434238, 0.13587654, -0.21821095, -0.028593391, -0.040001836, 0.06398056, 0.233339...</td>\n",
              "      <td>[[-0.17660215, 1.2277203, -0.06115333, -0.17026508, 1.0580376, -0.16798301, 0.24272121, -0.20983472, 0.08971207, 0.6569524, -0.27722386, 0.4281262, 0.48739827, 0.2324163, -0.47180232, -0.18792889, -0.19671606, -0.57597274, 0.12601036, 0.44215077,...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>10</th>\n",
              "      <td>Accidentally took 2 doses of tecta?I'm supposed to take 40mg of tecta daily, but I accidentally took it twice so I took 80mg in total, is that OK?</td>\n",
              "      <td>yes, you will be fine.</td>\n",
              "      <td>[[-0.11215795, 0.44342178, -0.22705616, 0.9130324, 0.6239934, -0.2341829, 0.99952507, -0.19205903, -0.39046597, 0.23505513, 0.89798194, -0.05028633, -0.43912324, 0.13103439, 0.46393242, -0.18600073, 0.46653593, 0.5945296, -0.09542866, 1.002146, 0...</td>\n",
              "      <td>[[0.06884122, 0.3991459, 0.13347371, 1.2714124, 0.4602924, 0.2689635, 0.4293988, -0.34511623, -0.07977429, -0.15078984, 0.1119453, -0.15782538, 0.13179636, 0.10379303, -0.1897872, 0.073030375, -0.048009794, -0.22115533, -0.16689084, 1.2068557, -0...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>11</th>\n",
              "      <td>Brian hemorrhage mother in ICU: Want to know if these things are normal.My mother suffered from a Subarachnoid hemorrhage stroke (SAH) on 1/9/15. She had an aneurysm rupture behind her left eye. She has been in the ICU this whole time. Some info:...</td>\n",
              "      <td>&amp;gt;4) Is it possible for TCD (transcranial doppler) and CAT scans to be wrong about vasospasms? \\n\\nSure, angiograms are still the gold standard. The evidence for the treatment of vasospasms in limited by the way, we do not no for sure if these ...</td>\n",
              "      <td>[[-0.2298152, -0.027373647, 0.2343978, 0.118794404, 0.040095247, -0.14495383, 0.55689496, -0.2184435, 0.4118657, 0.84105134, -0.022418566, 0.15133522, -0.030890863, 0.54792094, 0.16586299, 0.00252006, 0.4403717, 0.46651894, -0.19945136, 0.2714683...</td>\n",
              "      <td>[[0.10699771, 0.13907586, -0.16370507, 0.30486542, 0.4369713, -0.0777797, -0.0005571209, -0.32234883, -0.07883181, 0.04586037, -0.22734106, 0.11739552, 1.2917163, 0.50037754, -0.11399487, -0.027811646, 0.33034086, -0.1898757, -0.18361315, 0.08811...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>12</th>\n",
              "      <td>Solutions or Treatments for Simulator Sickness\\nGeneral question:\\nMy fiance has some issues with Simulator sickness. We've tried some solutions such as siting further back from the screen or changing the field of view for games or movies, but to...</td>\n",
              "      <td>There are other non-antihistaminic treatments for motion sickness, I would guess I would try these (like scopolamine). I do would want to discuss the risk/benefit ratio for using drugs to enjoy certain games.</td>\n",
              "      <td>[[-0.06768304, 0.2111865, 1.33728, 0.4093728, -0.037863445, -0.19909795, 0.59675986, -0.00724121, 1.2763453, 0.8271443, -0.050741434, 0.08688287, -0.23516633, 1.263954, -0.15680586, -0.090711355, 0.40230146, -0.109419316, -0.11487891, 0.41448542,...</td>\n",
              "      <td>[[-0.132732, 0.79169184, -0.15695727, 0.08610294, -0.084030524, -0.21557544, 0.43121457, -0.05919546, -0.050121624, 0.116889946, 0.16201825, 0.14344037, 0.22812246, 0.20972966, -0.009056047, -0.06952244, 0.17648898, 0.33555833, -0.22924715, 0.138...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>13</th>\n",
              "      <td>Should I be worried about my swollen lymph nodes?I'm a 17 y/o white F, 5 foot 1 and 118 pounds. For a little more than a week the lymph nodes in my left armpit have been swollen and painful both when touched and left on their own. In the past wee...</td>\n",
              "      <td>I think this warrants a trip to your doctor.</td>\n",
              "      <td>[[-0.10036704, 0.17197666, 0.6682855, -0.06802086, 0.22884023, -0.19962142, 0.55211335, -0.3986667, 0.6215303, 0.5883613, 0.56345475, 0.7833128, -0.002593013, 0.41028988, 0.35440135, -0.09089787, -0.038822114, 0.9048873, -0.11726918, 0.41297364, ...</td>\n",
              "      <td>[[0.15355928, 0.9022887, 0.19647257, 0.05897774, -0.037826687, 0.040987812, 0.65439725, -0.4417305, -0.15152603, -0.13688846, 0.085076965, 0.09020758, 1.3557999, -0.1647744, 0.29696614, -0.06793762, -0.16783336, 0.042502217, -0.113421805, 1.49819...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>14</th>\n",
              "      <td>My partner is a designate female and I also am female She keeps having OrgasmsApparently the average woman doesn't have Orgasms and I'm wondering if this amount of orgasms she has is in excess. I also have Orgasms.</td>\n",
              "      <td>&amp;gt;Apparently the average woman doesn't have Orgasms \\n\\nThat isn't true.\\n\\n&amp;gt;I'm wondering if this amount of orgasms she has is in excess\\n\\nExcess orgasms? What?</td>\n",
              "      <td>[[-0.251178, 0.36357123, 0.19599599, 0.4916827, 0.32055336, 0.0058548185, 0.58947575, -0.55425173, -0.35607582, 1.0378833, 0.64087886, 1.6529472, -0.07556924, 0.61150223, 0.1725991, -0.0116100665, 0.20288852, 0.7131314, -0.12291423, 0.37912995, -...</td>\n",
              "      <td>[[-0.29148155, 0.47658372, -0.04216112, 0.22375408, 0.19921552, -0.09857873, 0.42887354, -0.5406303, -0.28293437, 0.88321656, 0.019238628, 0.2642403, 0.8570628, 0.07455567, 0.18602714, 1.9101144, 0.122920565, -0.040849674, 0.18245947, 0.47146246,...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>15</th>\n",
              "      <td>24f. Chest pain lasting hours, getting worse. What do I do?I am a 24 year-old female. I have been experiencing chest pain off and on for a few weeks. It's mostly in or around my ribs under my breasts. It feels like a pressure. It is not necessari...</td>\n",
              "      <td>I would need much more information and i would actually want to see you to tell you anything other than go to the ER if you feel its serious. If the problem resolves itself defiantly call your primary care doc and talk to them. \\n  does the pain ...</td>\n",
              "      <td>[[-0.0062494543, 0.12361444, 0.59349835, 0.025204405, 0.2379374, -0.12211909, 0.5145799, -0.3951899, 1.1732261, 0.699885, -0.21227457, 0.46315265, -0.032447036, 0.26972327, 0.20156562, -0.05767897, -0.02102714, 0.47356787, -0.21486072, 0.21103245...</td>\n",
              "      <td>[[0.094878316, -0.12947361, -0.04107933, -0.25382018, 0.26031935, 0.12816827, 0.06646284, -0.05471387, -0.25389618, 0.335425, 0.005387549, -0.013414956, 0.06603424, -0.14320286, 0.26124674, 0.78168005, -0.0045633763, -0.23666911, 0.5200337, 0.251...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>16</th>\n",
              "      <td>Gynecomastia or Breast cancer?13\\nMale\\n177cm\\n60 kg\\nAmerican/Japanese\\nAt least 6 months\\nLeft nipple of breast\\nNo medical issues\\nNo medication\\n\\nI've had this bump that changes it's size and texture every now and again for at least 6 months...</td>\n",
              "      <td>Breast cancer in a 13 year old male is tremendously rare.\\n\\nGynaecomastia can take quite a while longer than 6 months to resolve.\\n\\n</td>\n",
              "      <td>[[-0.03490729, 0.27215007, 0.51699543, 0.5875977, 0.15197834, -0.100297995, 0.3306139, -0.34162968, 0.6238052, 0.24976122, 0.15855102, -0.027733712, -0.032541286, 0.55993277, 0.2579487, -0.03114066, -0.19984771, 1.0968158, 0.027874587, 0.24369775...</td>\n",
              "      <td>[[-0.1907793, 0.8906218, -0.110838704, 0.80821145, 0.46724653, -0.10856254, 0.44675112, -0.18396461, 0.32830828, 0.18334079, -0.26537588, 0.3562675, 1.3322723, 0.32925254, 0.104468204, -0.12629494, -0.07290969, -0.2992357, 0.09363668, 0.6341158, ...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>17</th>\n",
              "      <td>Worried about heart *thumps*Age 31\\n\\nSex Male\\n\\nHeight 197cm\\n\\nWeight 180kg\\n\\nRace Caucasian\\n\\nDuration of complaint 2 days\\n\\nLocation (Geographic and on body) Heart\\n\\nAny existing relevant medical issues (if any) Type 2 diabetic\\n\\nCurren...</td>\n",
              "      <td>&amp;gt;Danish names, hope it translates\\n\\nSure, metformin and losartan.\\n\\n&amp;gt;The past couple of days about 1-2 times an hour my heart has made this \"thump\" in my chest like it is beating extra hard one time.\\n\\nThat sounds like a ventricular extr...</td>\n",
              "      <td>[[-0.07611624, -0.022348253, 0.751212, 0.09780994, 0.086128175, -0.22028844, 0.83830035, -0.23856127, 0.6291239, 0.3971026, -0.0152027905, 0.36427912, -0.115015686, 0.40980598, 0.23551418, -0.07058594, -0.059574872, 0.4545892, -0.1583698, 0.31147...</td>\n",
              "      <td>[[-0.097172655, 0.07275775, -0.25377914, -0.15924218, 0.28145438, -0.06171313, 0.34107372, -0.179074, -0.126288, 0.2362424, -0.18745172, 0.24850127, 0.573665, -0.0249039, 0.17654635, 0.60749644, -0.1722704, -0.3090028, 0.047246233, 0.31476793, 0....</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>18</th>\n",
              "      <td>If two members of my extended family (aunt and uncle) were diagnosed with chronic leukemia, what is my chance of getting it?I was a smoker (recently quit), i'm 19 years old and my father does not have it. Although that same aunt also had vitiligo...</td>\n",
              "      <td>To date, we have no information on the existence of inheritable types of leukemia. So your chances are probably just as low as your next door neighbours chances. ,Do you know specifically what type of leukemia it is?,As /u murpahurp said, there i...</td>\n",
              "      <td>[[-0.17648198, 0.28411534, 0.38130414, 0.3100694, 0.20063773, -0.03262607, 0.9389497, -0.44264936, 1.9756128, -0.09574888, 1.3066144, -0.021018656, -0.2635293, -0.27166194, 0.15201254, 0.0023924613, 1.0857308, 0.9102626, 0.2169805, 0.48707527, -0...</td>\n",
              "      <td>[[-0.15957166, 0.40267903, -0.2987995, -0.20948935, 0.23491983, 0.03277729, 0.31468588, -0.15679967, -0.009091495, -0.03493221, -0.08620186, 0.060476154, -0.066437975, 0.07822373, -0.176918, -0.2508848, 0.036230676, -0.24474354, 0.32010782, 0.410...</td>\n",
              "    </tr>\n",
              "    <tr>\n",
              "      <th>19</th>\n",
              "      <td>23M getting constant mouth UlcersHi,\\n\\nI am getting mouth ulcers all the time, the current one is right on the stringy bit underneath your bottom teeth, and after using special mouthwash last night and Ulcer gel, it is horrible today.\\n\\nBeen ge...</td>\n",
              "      <td>The gum might have sodium luyrate sulphate, (SLS), it's a chemical that can cause an allergic reaction. Totally agree with stopping the gum.  If it's still persistent, speak to your doctor about aphthous-like ulcers, which can be systemic manifes...</td>\n",
              "      <td>[[-0.18158484, 0.24209644, 0.3155289, 0.76382697, 0.16301972, -0.1437822, 0.5974374, -0.40319166, 0.8555103, 0.43173182, 0.33494052, 0.8170414, -0.027123883, -0.035552304, 0.17036904, -0.034973294, -0.052836154, 1.4283096, 0.019494385, 0.13105609...</td>\n",
              "      <td>[[-0.047292054, 0.16946277, -0.14359778, -0.096518636, 0.0695647, 0.066515625, 0.057247654, 0.4592864, -0.19706547, 0.14917615, 0.29770166, 0.2808029, 0.23815095, 0.004138887, 0.14199351, 1.2531103, -0.20249727, -0.13582695, 0.69475114, 0.4762859...</td>\n",
              "    </tr>\n",
              "  </tbody>\n",
              "</table>\n",
              "</div>"
            ],
            "text/plain": [
              "                                                                                                                                                                                                                                                     question  \\\n",
              "0   Trying to get y friend to see a doctor but she wants to wait and see what happens. I'm worried sick and would like to know hat she might haveMy friend found a dime sized red lump a bit to the right of her clitoris in the shower this morning. its ...   \n",
              "1   Ease my worries pleaseMy husband is about to see a hematologist and googling around has me worried that he's got something serious, like aplastic anemia. I know we'll find out soon enough, but in the meantime, could you please suggest alternative...   \n",
              "2   Severe shoulder, neck and back pain after tetanus vaccinationA little less than a week ago I received my tetanus booster shot (the one you receive every decade, at least here in Australia).\\n\\nA few days later I began experiencing pain around my ...   \n",
              "3   Knee problemHere's the run down.  This past weekend my wife and I took part in a 3-day walk for breast cancer.  It was 60 miles, so clearly a lot of work on my knees.  Day 1 went fine, feet hurt, but to be expected.  Day two came and I was having...   \n",
              "4   Had a strange experience last night.Woke up in the middle of the night to take a leak. As I flushed the toilet I remember standing there feeling very light headed. I turned around and started to walk back to bed but never made it. Apparently I pa...   \n",
              "5                                Can anyone identify this?My 22 month old woke up with this.  We immediately took him to urgent care and they literally used the word, \"perplexed\" . We are waiting on an appointment on Monday. Any ideas would be helpful.    \n",
              "6   Bite, ingrown hair, infection?* [one](http://imgur.com/3901epB)\\n* [two](http://imgur.com/9w1QWlY)\\n* [three](http://imgur.com/TVDxF0H)\\n\\nAny idea what these are? The one on my cheek started off as a small scab (maybe a zit or something). I defi...   \n",
              "7   Busted my lip and need advice on how to heal it properly!I fell off my bike and busted my lip. I got four stitches on the inside, and just scratches on the outside. It is quite swollen and hard. I am hoping to get some advice on how make it heal ...   \n",
              "8   Just needed to know if this is \"normal\"- and ideally, why.The last 6-9 months, my (F,35) lymph nodes in my armpits painfully swell up about once a month, take about a week to go back to normal. When it first started happening, I went to an urgent...   \n",
              "9                                I've created a collection of amino acids and supplements that could potentially increase my release of HGH to 2000%-4000% what could be the consequences of executing this?I am under 18, so my plates have not yet closed.    \n",
              "10                                                                                                         Accidentally took 2 doses of tecta?I'm supposed to take 40mg of tecta daily, but I accidentally took it twice so I took 80mg in total, is that OK?   \n",
              "11  Brian hemorrhage mother in ICU: Want to know if these things are normal.My mother suffered from a Subarachnoid hemorrhage stroke (SAH) on 1/9/15. She had an aneurysm rupture behind her left eye. She has been in the ICU this whole time. Some info:...   \n",
              "12  Solutions or Treatments for Simulator Sickness\\nGeneral question:\\nMy fiance has some issues with Simulator sickness. We've tried some solutions such as siting further back from the screen or changing the field of view for games or movies, but to...   \n",
              "13  Should I be worried about my swollen lymph nodes?I'm a 17 y/o white F, 5 foot 1 and 118 pounds. For a little more than a week the lymph nodes in my left armpit have been swollen and painful both when touched and left on their own. In the past wee...   \n",
              "14                                     My partner is a designate female and I also am female She keeps having OrgasmsApparently the average woman doesn't have Orgasms and I'm wondering if this amount of orgasms she has is in excess. I also have Orgasms.   \n",
              "15  24f. Chest pain lasting hours, getting worse. What do I do?I am a 24 year-old female. I have been experiencing chest pain off and on for a few weeks. It's mostly in or around my ribs under my breasts. It feels like a pressure. It is not necessari...   \n",
              "16  Gynecomastia or Breast cancer?13\\nMale\\n177cm\\n60 kg\\nAmerican/Japanese\\nAt least 6 months\\nLeft nipple of breast\\nNo medical issues\\nNo medication\\n\\nI've had this bump that changes it's size and texture every now and again for at least 6 months...   \n",
              "17  Worried about heart *thumps*Age 31\\n\\nSex Male\\n\\nHeight 197cm\\n\\nWeight 180kg\\n\\nRace Caucasian\\n\\nDuration of complaint 2 days\\n\\nLocation (Geographic and on body) Heart\\n\\nAny existing relevant medical issues (if any) Type 2 diabetic\\n\\nCurren...   \n",
              "18  If two members of my extended family (aunt and uncle) were diagnosed with chronic leukemia, what is my chance of getting it?I was a smoker (recently quit), i'm 19 years old and my father does not have it. Although that same aunt also had vitiligo...   \n",
              "19  23M getting constant mouth UlcersHi,\\n\\nI am getting mouth ulcers all the time, the current one is right on the stringy bit underneath your bottom teeth, and after using special mouthwash last night and Ulcer gel, it is horrible today.\\n\\nBeen ge...   \n",
              "\n",
              "                                                                                                                                                                                                                                                       answer  \\\n",
              "0   This is most likely a Bartholin's Gland Cyst. On either side of the labia majora is a called a Bartholin's gland. Occasionally the ducts that empty the gland can become blocked causing the gland to develop a cyst. Sometimes they can go away on th...   \n",
              "1   Would be helpful with the exact values of the CBC. And B12, Folate and Ferritin values.\\n\\nAre liver and kidney function tests okay?\\n\\nWhat are his ethnic origins?,Is he diabetic. Does he take any other medication?,Does he take aspirin?\\nDid he ...   \n",
              "2   I seriously don't think your pain derives from the vaccination.\\n\\nIt looks like trapezoid contracture (is it the right word in english?).\\n\\nHeat and posture care should help you, elseways some muscular relaxant could be helpful.\\n\\nAnyways, at ...   \n",
              "3   It's possible that you caused some damage while playing sports and now with a heavy amount of activity caused aggravation of that injury. Its possible to cause a small tear in a meniscus and go years without any problems until a specific event ca...   \n",
              "4   Sounds like you had an episode of positional hypotension leading to syncope, or in other words, you stood up too fast causing a drop in blood pressure which made you pass out. If this was a one time thing you don't need to worry about it. Its pos...   \n",
              "5   It almost looks like prolonged exposure to something very hot. I'm not too sure what else it could be. Best of luck to you and your baby!,Yeah, my first thought was burning lesions, too.\\nThe other DD could be some pemphigoid lesion, but the skin...   \n",
              "6                                                          The ones in the beard look like Tinea, a fungal infection. \\nAnd I bet that the bigger one is also fungal, but made worse by scratching.\\n\\nYou should go to a GP for some anti fungal ointment...   \n",
              "7                                                                                                                                                                                                               Wash and wait.\\nTime is the only factor here.   \n",
              "8   This can be normal. This is happening every month, does it coincide with your medstrual cycle? Painful lymph nodes are nothing to worry about. This can happen with you have changes in hormones, when your body is trying to fight infections, etc. L...   \n",
              "9   You would develop Acromegaly, also known as Gigantism. It would have drastic effects on bone growth, fertility, muscle development, and several hormonal regulating systems in your body like sugar balance and insulin. You can check out the Wikiped...   \n",
              "10                                                                                                                                                                                                                                     yes, you will be fine.   \n",
              "11  &gt;4) Is it possible for TCD (transcranial doppler) and CAT scans to be wrong about vasospasms? \\n\\nSure, angiograms are still the gold standard. The evidence for the treatment of vasospasms in limited by the way, we do not no for sure if these ...   \n",
              "12                                           There are other non-antihistaminic treatments for motion sickness, I would guess I would try these (like scopolamine). I do would want to discuss the risk/benefit ratio for using drugs to enjoy certain games.   \n",
              "13                                                                                                                                                                                                               I think this warrants a trip to your doctor.   \n",
              "14                                                                                    &gt;Apparently the average woman doesn't have Orgasms \\n\\nThat isn't true.\\n\\n&gt;I'm wondering if this amount of orgasms she has is in excess\\n\\nExcess orgasms? What?   \n",
              "15  I would need much more information and i would actually want to see you to tell you anything other than go to the ER if you feel its serious. If the problem resolves itself defiantly call your primary care doc and talk to them. \\n  does the pain ...   \n",
              "16                                                                                                                     Breast cancer in a 13 year old male is tremendously rare.\\n\\nGynaecomastia can take quite a while longer than 6 months to resolve.\\n\\n   \n",
              "17  &gt;Danish names, hope it translates\\n\\nSure, metformin and losartan.\\n\\n&gt;The past couple of days about 1-2 times an hour my heart has made this \"thump\" in my chest like it is beating extra hard one time.\\n\\nThat sounds like a ventricular extr...   \n",
              "18  To date, we have no information on the existence of inheritable types of leukemia. So your chances are probably just as low as your next door neighbours chances. ,Do you know specifically what type of leukemia it is?,As /u murpahurp said, there i...   \n",
              "19  The gum might have sodium luyrate sulphate, (SLS), it's a chemical that can cause an allergic reaction. Totally agree with stopping the gum.  If it's still persistent, speak to your doctor about aphthous-like ulcers, which can be systemic manifes...   \n",
              "\n",
              "                                                                                                                                                                                                                                                Q_FFNN_embeds  \\\n",
              "0   [[0.05031391, 0.17522666, 0.71465725, 0.5769979, 0.32069182, -0.17807129, 1.2392216, -0.37865084, 0.1199767, 0.2758575, -0.002445519, 0.3054453, -0.11039174, 0.56973076, 0.120820425, -0.107291855, -0.17624098, 0.23657487, -0.23213816, 0.33558795,...   \n",
              "1   [[-0.068268515, 0.042960383, 0.17118096, 0.26986143, 0.112031415, -0.20294413, 0.7771517, -0.25849432, 0.59284496, 0.6635877, 0.3940065, -0.09514284, -0.089514874, 0.33704883, 0.2717219, -0.18564875, 0.1500851, 1.5225036, -0.21757159, 0.2978152, ...   \n",
              "2   [[-0.09599008, 0.03724689, 0.10206425, 0.4240935, 0.13334917, -0.043432925, 1.1233978, -0.24416606, 0.57163686, 0.4496103, -0.05453084, -0.060560953, -0.04965468, -0.28201678, 0.32567152, -0.12495111, -0.051384494, 1.0094256, -0.15498431, 0.43008...   \n",
              "3   [[-0.012918322, -0.020504545, 0.4435106, 0.19794388, 0.076883316, -0.21038833, 0.5508412, -0.16301246, 0.53401446, 0.48718905, 0.5478626, 0.13116859, -0.024213262, 0.0022163023, 0.28197163, -0.17161314, 0.30555886, 0.1917058, -0.40395558, 0.17525...   \n",
              "4   [[-0.10778567, 0.072568424, 0.6073649, -0.20827225, 0.17934273, -0.042293325, 0.39158764, -0.32003152, 0.3331981, 0.48051676, -0.10623282, 0.5591209, -0.18354987, 0.28779644, 0.28494167, 0.008892038, 0.57379186, 0.88093156, -0.15870328, 0.1819411...   \n",
              "5   [[-0.18035546, 0.091341786, 0.14185199, 0.26876837, 0.364697, -0.0028492103, 0.05263317, -0.23227215, 0.63868487, 0.459853, 0.3550713, 0.11367951, -0.5567823, 0.37561405, 0.040350173, -0.15050356, -0.09284662, -0.20346472, 0.07705624, 0.35358286,...   \n",
              "6   [[-0.045897443, 0.1859575, 0.79868317, 0.4142545, -0.039294146, -0.08599224, 0.92267793, -0.22851573, 0.56371015, 0.31517312, 0.77103704, 0.24593458, -0.032829843, 0.49358177, -0.040821023, 0.039925233, -0.23192735, 0.19133624, -0.45759693, 0.062...   \n",
              "7   [[0.049939808, 0.12046038, 0.61080974, 0.10166994, -0.14478658, -0.21728988, 1.2853746, -0.14180158, -0.00979681, 0.16179557, 0.2864955, 0.87758493, 0.10081489, 0.25402442, -0.12993337, 0.1418176, -0.2160801, -0.046122134, -0.31051943, 0.19090335...   \n",
              "8   [[0.010904644, 0.25103566, 0.13396052, 0.4604362, -0.030125968, 0.026252579, 0.6074764, -0.25831538, 0.34907365, 0.49096107, 0.46270916, 0.30601597, -0.049028505, 0.11198901, 0.24199407, -0.12763695, 0.0048868647, 0.40711734, -0.3820984, 0.378389...   \n",
              "9   [[-0.083161674, 0.30402392, 0.9112342, 0.16105938, 0.1272867, -0.22691977, 0.8712962, -0.15293598, 0.2285243, 0.69513017, 0.06952278, 0.027790995, -0.22886167, -0.08434238, 0.13587654, -0.21821095, -0.028593391, -0.040001836, 0.06398056, 0.233339...   \n",
              "10  [[-0.11215795, 0.44342178, -0.22705616, 0.9130324, 0.6239934, -0.2341829, 0.99952507, -0.19205903, -0.39046597, 0.23505513, 0.89798194, -0.05028633, -0.43912324, 0.13103439, 0.46393242, -0.18600073, 0.46653593, 0.5945296, -0.09542866, 1.002146, 0...   \n",
              "11  [[-0.2298152, -0.027373647, 0.2343978, 0.118794404, 0.040095247, -0.14495383, 0.55689496, -0.2184435, 0.4118657, 0.84105134, -0.022418566, 0.15133522, -0.030890863, 0.54792094, 0.16586299, 0.00252006, 0.4403717, 0.46651894, -0.19945136, 0.2714683...   \n",
              "12  [[-0.06768304, 0.2111865, 1.33728, 0.4093728, -0.037863445, -0.19909795, 0.59675986, -0.00724121, 1.2763453, 0.8271443, -0.050741434, 0.08688287, -0.23516633, 1.263954, -0.15680586, -0.090711355, 0.40230146, -0.109419316, -0.11487891, 0.41448542,...   \n",
              "13  [[-0.10036704, 0.17197666, 0.6682855, -0.06802086, 0.22884023, -0.19962142, 0.55211335, -0.3986667, 0.6215303, 0.5883613, 0.56345475, 0.7833128, -0.002593013, 0.41028988, 0.35440135, -0.09089787, -0.038822114, 0.9048873, -0.11726918, 0.41297364, ...   \n",
              "14  [[-0.251178, 0.36357123, 0.19599599, 0.4916827, 0.32055336, 0.0058548185, 0.58947575, -0.55425173, -0.35607582, 1.0378833, 0.64087886, 1.6529472, -0.07556924, 0.61150223, 0.1725991, -0.0116100665, 0.20288852, 0.7131314, -0.12291423, 0.37912995, -...   \n",
              "15  [[-0.0062494543, 0.12361444, 0.59349835, 0.025204405, 0.2379374, -0.12211909, 0.5145799, -0.3951899, 1.1732261, 0.699885, -0.21227457, 0.46315265, -0.032447036, 0.26972327, 0.20156562, -0.05767897, -0.02102714, 0.47356787, -0.21486072, 0.21103245...   \n",
              "16  [[-0.03490729, 0.27215007, 0.51699543, 0.5875977, 0.15197834, -0.100297995, 0.3306139, -0.34162968, 0.6238052, 0.24976122, 0.15855102, -0.027733712, -0.032541286, 0.55993277, 0.2579487, -0.03114066, -0.19984771, 1.0968158, 0.027874587, 0.24369775...   \n",
              "17  [[-0.07611624, -0.022348253, 0.751212, 0.09780994, 0.086128175, -0.22028844, 0.83830035, -0.23856127, 0.6291239, 0.3971026, -0.0152027905, 0.36427912, -0.115015686, 0.40980598, 0.23551418, -0.07058594, -0.059574872, 0.4545892, -0.1583698, 0.31147...   \n",
              "18  [[-0.17648198, 0.28411534, 0.38130414, 0.3100694, 0.20063773, -0.03262607, 0.9389497, -0.44264936, 1.9756128, -0.09574888, 1.3066144, -0.021018656, -0.2635293, -0.27166194, 0.15201254, 0.0023924613, 1.0857308, 0.9102626, 0.2169805, 0.48707527, -0...   \n",
              "19  [[-0.18158484, 0.24209644, 0.3155289, 0.76382697, 0.16301972, -0.1437822, 0.5974374, -0.40319166, 0.8555103, 0.43173182, 0.33494052, 0.8170414, -0.027123883, -0.035552304, 0.17036904, -0.034973294, -0.052836154, 1.4283096, 0.019494385, 0.13105609...   \n",
              "\n",
              "                                                                                                                                                                                                                                                A_FFNN_embeds  \n",
              "0   [[-0.09869906, 0.20935602, -0.42185766, -0.33665547, 0.48797682, -0.007028032, 0.07065214, -0.16578242, -0.26237178, 0.24004409, -0.22438423, 0.18115889, 0.4567215, -0.02180059, 0.14635685, 0.74769473, -0.026884364, -0.2658844, 0.35665464, 0.3084...  \n",
              "1   [[0.02158143, -0.082602814, -0.17985626, -0.19048187, 0.022836702, -0.09730069, 0.3418817, -0.15769783, -0.10843049, 0.15295486, 0.18546492, 0.09176144, 0.64303726, 0.27884188, 0.041989554, 0.09366697, 0.1290735, -0.11779204, 0.46386075, 0.239391...  \n",
              "2   [[-0.16730975, 0.06444351, 0.009257315, 0.13030894, 0.1986657, 0.111179024, 0.050693758, -0.2810906, -0.16696753, 0.22874801, 0.060951676, 0.024106182, 0.10953758, -0.14491685, 0.23797303, 0.14848688, -0.06242373, -0.3347124, 0.35131043, 0.427723...  \n",
              "3   [[-0.06909141, -0.11909217, -0.2177947, -0.31697032, 0.045378305, 0.26905084, 0.2377099, -0.05351404, -0.14071696, 0.2628327, 0.056118537, -0.07538253, 0.8720115, -0.14583397, 0.07096485, 0.5082699, 0.21771231, -0.33978415, 0.3260417, 0.27947804,...  \n",
              "4   [[0.11793654, 0.3220811, -0.26831508, -0.3226437, 0.24534544, 0.12237222, -0.06575933, -0.31571254, -0.40923232, 0.35130405, -0.117886476, -0.11570231, 0.7159771, 0.14493895, -0.055149883, 1.7910986, 0.090899386, -0.27257594, -0.0984668, 0.167966...  \n",
              "5   [[-0.087587915, 0.27886966, 0.00762948, -0.13448302, 0.022136038, 0.11770341, 0.018516716, -0.24967742, -0.2663802, 0.43704742, -0.024136174, 0.016769279, -0.21972813, 0.099903345, 0.069671065, 0.35788065, 0.19415134, -0.3672943, 0.0820634, 0.321...  \n",
              "6   [[-0.08411021, 0.18407981, -0.08899195, -0.027661212, 0.20925134, 0.26197487, 0.0931475, -0.3652377, -0.3545009, 0.22874103, -0.05313527, 0.24930356, -0.21285923, 0.047569856, 0.13853699, 1.0090455, -0.08114073, -0.19877541, -0.15805234, 0.389106...  \n",
              "7   [[0.36118168, 0.53679043, 0.09158689, 0.35620704, 0.8140732, -0.2866227, 0.49343473, -0.25351965, -0.04140351, -0.11406509, -0.5413259, 0.550707, 0.13118742, 0.40300626, -0.070892334, -0.1997576, 0.60152066, 0.44648597, -0.07755573, 0.65332866, 0...  \n",
              "8   [[-0.058995415, 0.09620386, -0.160867, -0.252489, -0.10947582, 0.06575855, 0.3831236, -0.32797176, -0.25833452, 0.16688618, 0.013157929, 0.23609565, 0.80914056, 0.25079644, 0.2155992, 1.3976666, 0.07401086, -0.22676554, -0.05611816, 0.37811735, -...  \n",
              "9   [[-0.17660215, 1.2277203, -0.06115333, -0.17026508, 1.0580376, -0.16798301, 0.24272121, -0.20983472, 0.08971207, 0.6569524, -0.27722386, 0.4281262, 0.48739827, 0.2324163, -0.47180232, -0.18792889, -0.19671606, -0.57597274, 0.12601036, 0.44215077,...  \n",
              "10  [[0.06884122, 0.3991459, 0.13347371, 1.2714124, 0.4602924, 0.2689635, 0.4293988, -0.34511623, -0.07977429, -0.15078984, 0.1119453, -0.15782538, 0.13179636, 0.10379303, -0.1897872, 0.073030375, -0.048009794, -0.22115533, -0.16689084, 1.2068557, -0...  \n",
              "11  [[0.10699771, 0.13907586, -0.16370507, 0.30486542, 0.4369713, -0.0777797, -0.0005571209, -0.32234883, -0.07883181, 0.04586037, -0.22734106, 0.11739552, 1.2917163, 0.50037754, -0.11399487, -0.027811646, 0.33034086, -0.1898757, -0.18361315, 0.08811...  \n",
              "12  [[-0.132732, 0.79169184, -0.15695727, 0.08610294, -0.084030524, -0.21557544, 0.43121457, -0.05919546, -0.050121624, 0.116889946, 0.16201825, 0.14344037, 0.22812246, 0.20972966, -0.009056047, -0.06952244, 0.17648898, 0.33555833, -0.22924715, 0.138...  \n",
              "13  [[0.15355928, 0.9022887, 0.19647257, 0.05897774, -0.037826687, 0.040987812, 0.65439725, -0.4417305, -0.15152603, -0.13688846, 0.085076965, 0.09020758, 1.3557999, -0.1647744, 0.29696614, -0.06793762, -0.16783336, 0.042502217, -0.113421805, 1.49819...  \n",
              "14  [[-0.29148155, 0.47658372, -0.04216112, 0.22375408, 0.19921552, -0.09857873, 0.42887354, -0.5406303, -0.28293437, 0.88321656, 0.019238628, 0.2642403, 0.8570628, 0.07455567, 0.18602714, 1.9101144, 0.122920565, -0.040849674, 0.18245947, 0.47146246,...  \n",
              "15  [[0.094878316, -0.12947361, -0.04107933, -0.25382018, 0.26031935, 0.12816827, 0.06646284, -0.05471387, -0.25389618, 0.335425, 0.005387549, -0.013414956, 0.06603424, -0.14320286, 0.26124674, 0.78168005, -0.0045633763, -0.23666911, 0.5200337, 0.251...  \n",
              "16  [[-0.1907793, 0.8906218, -0.110838704, 0.80821145, 0.46724653, -0.10856254, 0.44675112, -0.18396461, 0.32830828, 0.18334079, -0.26537588, 0.3562675, 1.3322723, 0.32925254, 0.104468204, -0.12629494, -0.07290969, -0.2992357, 0.09363668, 0.6341158, ...  \n",
              "17  [[-0.097172655, 0.07275775, -0.25377914, -0.15924218, 0.28145438, -0.06171313, 0.34107372, -0.179074, -0.126288, 0.2362424, -0.18745172, 0.24850127, 0.573665, -0.0249039, 0.17654635, 0.60749644, -0.1722704, -0.3090028, 0.047246233, 0.31476793, 0....  \n",
              "18  [[-0.15957166, 0.40267903, -0.2987995, -0.20948935, 0.23491983, 0.03277729, 0.31468588, -0.15679967, -0.009091495, -0.03493221, -0.08620186, 0.060476154, -0.066437975, 0.07822373, -0.176918, -0.2508848, 0.036230676, -0.24474354, 0.32010782, 0.410...  \n",
              "19  [[-0.047292054, 0.16946277, -0.14359778, -0.096518636, 0.0695647, 0.066515625, 0.057247654, 0.4592864, -0.19706547, 0.14917615, 0.29770166, 0.2808029, 0.23815095, 0.004138887, 0.14199351, 1.2531103, -0.20249727, -0.13582695, 0.69475114, 0.4762859...  "
            ]
          },
          "metadata": {
            "tags": []
          },
          "execution_count": 29
        }
      ]
    },
    {
      "metadata": {
        "id": "A7z5HZu_y1xT",
        "colab_type": "code",
        "colab": {}
      },
      "cell_type": "code",
      "source": [
        "askDocspd.to_csv('askDocsFFNNEmbeddings.csv')"
      ],
      "execution_count": 0,
      "outputs": []
    },
    {
      "metadata": {
        "id": "4zENkrs3zEMU",
        "colab_type": "code",
        "colab": {}
      },
      "cell_type": "code",
      "source": [
        "os.listdir()"
      ],
      "execution_count": 0,
      "outputs": []
    },
    {
      "metadata": {
        "id": "Ol671kJPOGO8",
        "colab_type": "code",
        "colab": {}
      },
      "cell_type": "code",
      "source": [
        "# os.remove(\"webMDFFNNEmbeddings.csv\")"
      ],
      "execution_count": 0,
      "outputs": []
    },
    {
      "metadata": {
        "id": "-BHH9hic0o9Z",
        "colab_type": "code",
        "outputId": "1829b885-8f9d-4f83-b5a1-e57769d6b09c",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 50
        }
      },
      "cell_type": "code",
      "source": [
        "!pip install -U -q PyDrive\n",
        "\n",
        "from pydrive.auth import GoogleAuth\n",
        "from pydrive.drive import GoogleDrive\n",
        "from google.colab import auth\n",
        "from oauth2client.client import GoogleCredentials\n",
        "\n",
        "# 1. Authenticate and create the PyDrive client.\n",
        "auth.authenticate_user()\n",
        "gauth = GoogleAuth()\n",
        "gauth.credentials = GoogleCredentials.get_application_default()\n",
        "drive = GoogleDrive(gauth)\n"
      ],
      "execution_count": 0,
      "outputs": [
        {
          "output_type": "stream",
          "text": [
            "\u001b[?25l\r\u001b[K    1% |▎                               | 10kB 26.3MB/s eta 0:00:01\r\u001b[K    2% |▋                               | 20kB 2.3MB/s eta 0:00:01\r\u001b[K    3% |█                               | 30kB 3.3MB/s eta 0:00:01\r\u001b[K    4% |█▎                              | 40kB 2.1MB/s eta 0:00:01\r\u001b[K    5% |█▋                              | 51kB 2.7MB/s eta 0:00:01\r\u001b[K    6% |██                              | 61kB 3.2MB/s eta 0:00:01\r\u001b[K    7% |██▎                             | 71kB 3.6MB/s eta 0:00:01\r\u001b[K    8% |██▋                             | 81kB 4.1MB/s eta 0:00:01\r\u001b[K    9% |███                             | 92kB 4.6MB/s eta 0:00:01\r\u001b[K    10% |███▎                            | 102kB 3.5MB/s eta 0:00:01\r\u001b[K    11% |███▋                            | 112kB 3.5MB/s eta 0:00:01\r\u001b[K    12% |████                            | 122kB 5.0MB/s eta 0:00:01\r\u001b[K    13% |████▎                           | 133kB 4.9MB/s eta 0:00:01\r\u001b[K    14% |████▋                           | 143kB 9.2MB/s eta 0:00:01\r\u001b[K    15% |█████                           | 153kB 9.2MB/s eta 0:00:01\r\u001b[K    16% |█████▎                          | 163kB 9.1MB/s eta 0:00:01\r\u001b[K    17% |█████▋                          | 174kB 9.1MB/s eta 0:00:01\r\u001b[K    18% |██████                          | 184kB 9.2MB/s eta 0:00:01\r\u001b[K    19% |██████▎                         | 194kB 9.2MB/s eta 0:00:01\r\u001b[K    20% |██████▋                         | 204kB 38.5MB/s eta 0:00:01\r\u001b[K    21% |███████                         | 215kB 10.7MB/s eta 0:00:01\r\u001b[K    22% |███████▎                        | 225kB 10.7MB/s eta 0:00:01\r\u001b[K    23% |███████▋                        | 235kB 10.7MB/s eta 0:00:01\r\u001b[K    24% |████████                        | 245kB 10.8MB/s eta 0:00:01\r\u001b[K    25% |████████▎                       | 256kB 10.8MB/s eta 0:00:01\r\u001b[K    26% |████████▋                       | 266kB 10.3MB/s eta 0:00:01\r\u001b[K    27% |█████████                       | 276kB 10.4MB/s eta 0:00:01\r\u001b[K    29% |█████████▎                      | 286kB 10.4MB/s eta 0:00:01\r\u001b[K    30% |█████████▋                      | 296kB 10.3MB/s eta 0:00:01\r\u001b[K    31% |██████████                      | 307kB 10.8MB/s eta 0:00:01\r\u001b[K    32% |██████████▎                     | 317kB 41.8MB/s eta 0:00:01\r\u001b[K    33% |██████████▋                     | 327kB 42.6MB/s eta 0:00:01\r\u001b[K    34% |███████████                     | 337kB 44.5MB/s eta 0:00:01\r\u001b[K    35% |███████████▎                    | 348kB 39.3MB/s eta 0:00:01\r\u001b[K    36% |███████████▋                    | 358kB 39.4MB/s eta 0:00:01\r\u001b[K    37% |████████████                    | 368kB 48.1MB/s eta 0:00:01\r\u001b[K    38% |████████████▎                   | 378kB 48.7MB/s eta 0:00:01\r\u001b[K    39% |████████████▋                   | 389kB 49.3MB/s eta 0:00:01\r\u001b[K    40% |█████████████                   | 399kB 13.0MB/s eta 0:00:01\r\u001b[K    41% |█████████████▎                  | 409kB 13.0MB/s eta 0:00:01\r\u001b[K    42% |█████████████▋                  | 419kB 13.0MB/s eta 0:00:01\r\u001b[K    43% |██████████████                  | 430kB 13.0MB/s eta 0:00:01\r\u001b[K    44% |██████████████▎                 | 440kB 13.0MB/s eta 0:00:01\r\u001b[K    45% |██████████████▋                 | 450kB 13.4MB/s eta 0:00:01\r\u001b[K    46% |███████████████                 | 460kB 13.3MB/s eta 0:00:01\r\u001b[K    47% |███████████████▎                | 471kB 13.3MB/s eta 0:00:01\r\u001b[K    48% |███████████████▋                | 481kB 13.2MB/s eta 0:00:01\r\u001b[K    49% |████████████████                | 491kB 13.1MB/s eta 0:00:01\r\u001b[K    50% |████████████████▎               | 501kB 50.3MB/s eta 0:00:01\r\u001b[K    51% |████████████████▋               | 512kB 46.8MB/s eta 0:00:01\r\u001b[K    52% |█████████████████               | 522kB 47.5MB/s eta 0:00:01\r\u001b[K    53% |█████████████████▎              | 532kB 48.9MB/s eta 0:00:01\r\u001b[K    54% |█████████████████▋              | 542kB 11.3MB/s eta 0:00:01\r\u001b[K    55% |██████████████████              | 552kB 11.4MB/s eta 0:00:01\r\u001b[K    57% |██████████████████▎             | 563kB 11.4MB/s eta 0:00:01\r\u001b[K    58% |██████████████████▋             | 573kB 11.4MB/s eta 0:00:01\r\u001b[K    59% |███████████████████             | 583kB 11.4MB/s eta 0:00:01\r\u001b[K    60% |███████████████████▎            | 593kB 11.5MB/s eta 0:00:01\r\u001b[K    61% |███████████████████▋            | 604kB 11.5MB/s eta 0:00:01\r\u001b[K    62% |████████████████████            | 614kB 11.8MB/s eta 0:00:01\r\u001b[K    63% |████████████████████▎           | 624kB 11.8MB/s eta 0:00:01\r\u001b[K    64% |████████████████████▋           | 634kB 11.8MB/s eta 0:00:01\r\u001b[K    65% |█████████████████████           | 645kB 62.8MB/s eta 0:00:01\r\u001b[K    66% |█████████████████████▎          | 655kB 64.3MB/s eta 0:00:01\r\u001b[K    67% |█████████████████████▋          | 665kB 47.4MB/s eta 0:00:01\r\u001b[K    68% |██████████████████████          | 675kB 47.2MB/s eta 0:00:01\r\u001b[K    69% |██████████████████████▎         | 686kB 46.9MB/s eta 0:00:01\r\u001b[K    70% |██████████████████████▋         | 696kB 45.9MB/s eta 0:00:01\r\u001b[K    71% |███████████████████████         | 706kB 44.8MB/s eta 0:00:01\r\u001b[K    72% |███████████████████████▎        | 716kB 44.0MB/s eta 0:00:01\r\u001b[K    73% |███████████████████████▋        | 727kB 42.9MB/s eta 0:00:01\r\u001b[K    74% |████████████████████████        | 737kB 42.1MB/s eta 0:00:01\r\u001b[K    75% |████████████████████████▎       | 747kB 42.0MB/s eta 0:00:01\r\u001b[K    76% |████████████████████████▋       | 757kB 42.1MB/s eta 0:00:01\r\u001b[K    77% |████████████████████████▉       | 768kB 56.3MB/s eta 0:00:01\r\u001b[K    78% |█████████████████████████▏      | 778kB 58.2MB/s eta 0:00:01\r\u001b[K    79% |█████████████████████████▌      | 788kB 57.6MB/s eta 0:00:01\r\u001b[K    80% |█████████████████████████▉      | 798kB 59.0MB/s eta 0:00:01\r\u001b[K    81% |██████████████████████████▏     | 808kB 59.4MB/s eta 0:00:01\r\u001b[K    82% |██████████████████████████▌     | 819kB 59.6MB/s eta 0:00:01\r\u001b[K    83% |██████████████████████████▉     | 829kB 60.7MB/s eta 0:00:01\r\u001b[K    85% |███████████████████████████▏    | 839kB 59.9MB/s eta 0:00:01\r\u001b[K    86% |███████████████████████████▌    | 849kB 58.4MB/s eta 0:00:01\r\u001b[K    87% |███████████████████████████▉    | 860kB 51.1MB/s eta 0:00:01\r\u001b[K    88% |████████████████████████████▏   | 870kB 49.4MB/s eta 0:00:01\r\u001b[K    89% |████████████████████████████▌   | 880kB 48.8MB/s eta 0:00:01\r\u001b[K    90% |████████████████████████████▉   | 890kB 48.7MB/s eta 0:00:01\r\u001b[K    91% |█████████████████████████████▏  | 901kB 48.4MB/s eta 0:00:01\r\u001b[K    92% |█████████████████████████████▌  | 911kB 49.4MB/s eta 0:00:01\r\u001b[K    93% |█████████████████████████████▉  | 921kB 50.1MB/s eta 0:00:01\r\u001b[K    94% |██████████████████████████████▏ | 931kB 51.3MB/s eta 0:00:01\r\u001b[K    95% |██████████████████████████████▌ | 942kB 53.0MB/s eta 0:00:01\r\u001b[K    96% |██████████████████████████████▉ | 952kB 54.0MB/s eta 0:00:01\r\u001b[K    97% |███████████████████████████████▏| 962kB 63.2MB/s eta 0:00:01\r\u001b[K    98% |███████████████████████████████▌| 972kB 66.0MB/s eta 0:00:01\r\u001b[K    99% |███████████████████████████████▉| 983kB 68.6MB/s eta 0:00:01\r\u001b[K    100% |████████████████████████████████| 993kB 24.3MB/s \n",
            "\u001b[?25h  Building wheel for PyDrive (setup.py) ... \u001b[?25ldone\n",
            "\u001b[?25h"
          ],
          "name": "stdout"
        }
      ]
    },
    {
      "metadata": {
        "id": "GwNo3K_EGID0",
        "colab_type": "code",
        "colab": {}
      },
      "cell_type": "code",
      "source": [
        "auth.authenticate_user()\n",
        "gauth = GoogleAuth()\n",
        "gauth.credentials = GoogleCredentials.get_application_default()\n",
        "drive = GoogleDrive(gauth)"
      ],
      "execution_count": 0,
      "outputs": []
    },
    {
      "metadata": {
        "id": "L4dZA-iFz-3q",
        "colab_type": "code",
        "outputId": "92bf6535-7612-45f5-a6fb-9a266301700a",
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 487
        }
      },
      "cell_type": "code",
      "source": [
        "# 2. Create & upload a file text file.\n",
        "uploadModel = drive.CreateFile()\n",
        "uploaded = drive.CreateFile()\n",
        "uploadModel.SetContentFile( 'askDocsFFNNEmbeddings.csv')\n",
        "uploadModel.Upload()"
      ],
      "execution_count": 0,
      "outputs": [
        {
          "output_type": "stream",
          "text": [
            "W0427 05:58:06.826507 140313095235456 __init__.py:44] file_cache is unavailable when using oauth2client >= 4.0.0\n",
            "Traceback (most recent call last):\n",
            "  File \"/usr/local/lib/python3.6/dist-packages/googleapiclient/discovery_cache/__init__.py\", line 36, in autodetect\n",
            "    from google.appengine.api import memcache\n",
            "ModuleNotFoundError: No module named 'google.appengine'\n",
            "\n",
            "During handling of the above exception, another exception occurred:\n",
            "\n",
            "Traceback (most recent call last):\n",
            "  File \"/usr/local/lib/python3.6/dist-packages/googleapiclient/discovery_cache/file_cache.py\", line 33, in <module>\n",
            "    from oauth2client.contrib.locked_file import LockedFile\n",
            "ModuleNotFoundError: No module named 'oauth2client.contrib.locked_file'\n",
            "\n",
            "During handling of the above exception, another exception occurred:\n",
            "\n",
            "Traceback (most recent call last):\n",
            "  File \"/usr/local/lib/python3.6/dist-packages/googleapiclient/discovery_cache/file_cache.py\", line 37, in <module>\n",
            "    from oauth2client.locked_file import LockedFile\n",
            "ModuleNotFoundError: No module named 'oauth2client.locked_file'\n",
            "\n",
            "During handling of the above exception, another exception occurred:\n",
            "\n",
            "Traceback (most recent call last):\n",
            "  File \"/usr/local/lib/python3.6/dist-packages/googleapiclient/discovery_cache/__init__.py\", line 41, in autodetect\n",
            "    from . import file_cache\n",
            "  File \"/usr/local/lib/python3.6/dist-packages/googleapiclient/discovery_cache/file_cache.py\", line 41, in <module>\n",
            "    'file_cache is unavailable when using oauth2client >= 4.0.0')\n",
            "ImportError: file_cache is unavailable when using oauth2client >= 4.0.0\n"
          ],
          "name": "stderr"
        }
      ]
    }
  ]
}